Moxa V2616A-C5-W7E [21/111] Apt installing and removing packages

Moxa V2616A-C5-CT-LX [21/111] Apt installing and removing packages
V2616A Linux Software Configuration
2-14
APTInstalling and Removing Packages
APT is the Debian tool used to install and remove packages. Before installing a package, you need to configure
the apt source file, /etc/apt/sources.list, which is located in the read-only partition.
1. Mount the root file system with write permission.
MOXA:~# mount -o remount,rw
2. Next, use vi editor to configure /etc/apt/sources.list.
MOXA:~# vi /etc/apt/sources.list
#
# deb cdrom:[Debian GNU/Linux 6.0.2.1 _Squeeze_ - Official amd64 NETINST Binary-
1
20110628-12:58]/ Squeeze main
#deb cdrom:[Debian GNU/Linux 6.0.2.1 _Squeeze_ - Official amd64 NETINST Binary-
1
20110628-12:58]/ Squeeze main
deb http://ftp.us.debian.org/debian/ squeeze main
deb-src http://ftp.us.debian.org/debian/ squeeze main
deb http://security.debian.org/ squeeze/updates main
deb-src http://security.debian.org/ squeeze/updates main
# squeeze-updates, previously known as ‘volatile’
deb http://ftp.us.debian.org/debian squeeze-updates main
deb-src http://ftp.us.debian.org/debian squeeze-updates main
3. Update the source list after you configure it.
MOXA:~# apt-get update
MOXA:~#
4. Once you indicate which package you want to install (openswan, for example), type:
MOXA:~# apt-get install openswan
MOXA:~#
5. Use one of the following commands to remove a package:
a. For a simple package removal:
MOXA:~# apt-get remove openswan
MOXA:~#
b. For a complete package removal:
MOXA:~# apt-get remove openswan --purge
MOXA:~#
6. If the installation is complete, remember to umount the root directory back to read-only mode.
MOXA:~# umount /
MOXA:~#
ATTENTION
The APT cache space /
var/cache/apt is located in tmpfs. If you need to install a huge package, link
/
var/cache/apt to USB mass storage or mount it to an NFS space to generate more free space. Use df h to
check
how much free space is available on tmpfs.

Содержание

Похожие устройства

Скачать