linux嵌入式移植部分配置


取消文件系统登录信息(文件系统自动登录)

  • 将/etc/inittab文件中的:
console::respawn:/sbin/getty -L console 0 vt100 # GENERLC_SERIAL

将改行改为以下内容(如果没有则添加以下内容)

console::respawn:-/bin/sh

开发板网卡IP初始化配置

静态IP配置

  • 在/etc/network/interfaces文件中,(没有可添加)
# interfaces(5) file used by ifup(8) and ifdown(8)
auto lo
iface lo inet loopback

#以下为配置enp2s0网卡为静态IP 192.168.10.201
auto enp2s0
iface enp2s0 inet static
address 192.168.10.201
netmask 255.255.255.0
gateway 192.168.10.1
broadcast 192.168.10.255

DHCP动态指定IP获取

  • 同样文件中修改
# interfaces(5) file used by ifup(8) and ifdown(8)
auto lo
iface lo inet loopback

auto enp2s0
iface enp2s0 inet dhcp
#指定DHCP获取IP地址范围
pre-up ifconfig enp2s0:0 192.168.10.94 
up ifconfig enp2s0:0 192.168.10.94

压缩包解压和打包操作

cpio解压和打包

  • 解压
cpio -idmv < test.cpio
  • 打包
find ./* | cpio -H newc -o > test.cpio

gzip解压和打包

  • 解压
gunzip test.gz
  • 打包
gzip test/
  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值