5. Do a good job in Linux: 21 ask 70. How do I check the Linux hard disk usage? In the Linux environment, you can use the DF command to view the use of the hard disk. Below is a DF -T -H (-t parameter: display file system type, -h parameter to display information with high readability) command input instance: FileSystem Type Size Used Avail Use% MOUNTEDON / DEV / HDA1 EXT2 7.5G 4.7G 2.5G 65% / / DEV / HDA2 EXT2 653M 6.6M 613M 1% / Root / DEV / HDB1 EXT2 7.5G 3.5G 3.7G 49% / usr 71.Linux What compression tools? There are many compression tools under Linux, commonly used: 1) Gzip / gunzip: This is the free software developed by GNU, which is quite wide. The compressed file extension is ".gz". How to use is simple, for example: gunzip eos.gz gzip /Home/test/*.txt; 2) compress / uncompress: This is a pair of historic compression programs, and the file is compressed after it is compressed. " Z". 3) In addition to this: ZIP / UNZIP, BZIP2 / BUNZIP2, etc. 72. How to manage processes? The process is an execution of the program. You can use "PS -AUXW" to list the details of the process currently executing, including process ID numbers in each process. You can terminate this process through the "Kill Process ID". 73. What does the authority of the file or directory mean? The permission bit of the file or directory consists of 10 bits, such as -RWXR-XR-X. 1) The first representative file / directory type: D represents the directory, - represents the file, L representation link; 2) The remaining 9 points into 3 groups, 3 digits per group; 2-4 bit describe the authority of the file owner, 5 -7 bit describes the permissions of the same user group with the file owner, and 8-10 bits is the permissions of other users. 3) RWX: The three of each group are: read permissions, write permissions, execute permissions; if it is - do not have this permission. That is to say that -RWXR-XR-X is represented, this is a normal file, the file owner can read, write, execute this file, and can read and execute this file with the user of the file owner, and other users. 74. What is a user account? In the Linux system, you can identify each user through a user account, and enter a different user account and password when logging in to determine your identity. That is, the Linux system passes all users of the user account and the management system. Then you can create some user groups to join the user to the group to get the permissions of the user group. 75. How to manage users under Linux? If you want to add a user: 1) Log in with root, then execute "AddUser User Account Name 2) Execute" PasswD User Account Name "to set a password for this user account.
Execute "UserDel User Account" to delete a user; execute "GroupAdd User Group Name" Add a user group; execute the GroupDel User Group Name Delete a user group; 76. How to make a disk limit for the user? 1) The partition of the disk limit will be set, modify the / etc / fstab file in the following format: / dev / hda2 / home ext2 defaults, USRQUOTA 1 2 2) Create an empty file quota.user #touch under the partition directory to set the disk limit /Home/quota.user #chmod 600 /Home/quota.user 3) After restarting the system, you can use the Edquota -u username to set. 77. How to back up the system? In Linux, you can use the dump / restore command group to implement the system's backup and recovery. Suppose you need to complete all the files under the / usr directory to the tape drive (assuming that the device is RMT8, different tape drives are different), you can use the command: dump -o -f / dev / rmt8 / usr's -O The parameter represents the full file, the "-f device file name" parameter specifies where the backup is home, and the last directory name specifies the content to be backed up. You can then use the following command to recover: restore -r -f / dev / rmt8 78. How to install .tar packages? Linux software has two release methods: one is a source code, and the other is an executable file package. Most of the release packs are first archived, and then compress them with Gzip, and generate files ended with .tar.gz. You can use the "TAR XVFZ file name" to complete the decompression and solve the TAR package. If you get an executable file package, the installation work is over. If you get a source package, you also need to compile: 1) Run "./configure" in the decompression directory; 2) Run "Make" in the decompression directory; 3) Run "make install" installation . 79. How do I use rpm to install Linux software? RPM tools provided by Redhat make it more convenient to install Linux software installation. 1) Install: rpm -ivh somesoft.rpm 2) Anti-installation: rpm -e somesoft.rpm 3) query: rpm -q somesoft 80. If you forget the password of the root, what should I do? If you forget the password of the root, you can restore: 1) Restart Linux, when LILO: When you enter LinuxSingle to enter a single user mode; Set the password of the root. 81. What should I do when reloading Windows? In this case, two method recovery: 1) Start with the Linux boot floppy disk, then execute / sbin / lib, re-establish LILO; 2) Start using the Linux installation CD, select the upgrade system, will rebuild LILO.
82. How to make a Linux boot disk? Under Linux, there is a tool MkBootDisk to make a system boot disk: 1) View the system version, can be seen by LS / USR / SRC; 2) Insert an empty floppy disk; 3) Execute "mkbootdisk --verbose 2.2.5 ". 83. How to use Linux remote? We can use Telnet, Rlogin, RSH, RCP and other commands to implement remote use Linux, but this method is clearly transmitted in the transmission process, so it is possible to bring many unsafe factors. Therefore, you should try to avoid remote use root account login systems. How to build a safe remote login? Using SSH to achieve secure remote login because SSH implements encryption of data transmission. 1) Get the SSH-1.26.Tar.gz file; 2) Unlock this package with TAR XVPF SSH-1.26.tar.gz; 3) Execute it under the unlocked directory /us r / lock/src/ssh-1.26 directory. / configure; 4) Execute Make and make install to complete compilation and installation. 5) You can use SSH to create a secure remote connection with a server installed SSH. 85. How to run a planned task? It is much more familiar to planning tasks in Windows, which can complete some tasks at some simple settings. In the maintenance of Linux systems, we can also need to perform some tasks regularly. This can be used: 1) AT command: It can read the instructions in the keyboard or file, then execute in the specified time; 2) crontab wait : Perform some tasks by setting its profile. 86. What did the boot process of Linux? 1) One boot, the CPU hands the control to the BIOS, BIOS completes the power-on self-test; 2) The BIOS is then read on the first sector on the disk and loaded into the Lilo of the main boot sector; 3) LILO selection according to the input selection Different kernel images, if you select Linux to read the core image under / boot; 4) Initialization of the core start hardware detection and device driver, then run the init 5) Init process according to the configuration of / etc / inittab A series of initialization scripts; 6) After completing, start the Getty process to accept the user's login. 87. How do I set the boot automatic running program? You can join the commands you want to start the system in the following scripts: /etc/rc.local ,/etc/rc.sinit, and /etc/rc.d/init.d. 88. Why do you need to recompile the kernel? You need to recompile the kernel or add a dynamic kernel module: 1) Update the driver; 2) Customize the most reliable kernel according to your own needs; 3) Upgrade the Linux kernel.
89. How to recompile the kernel? 1) Enter Linux Source Chat Directory: CD / USR / SRC / Linux 2) Execute "Make Config" or "Make MenuConfig", "Make XConfig" Configure the kernel option, select the module you want, remove unwanted modules; 3 The "Make Zimage" command is executed. After about 30 to 90 minutes, a zimage new kernel image file is generated, stored in / usr / src / linux / arch / i386 / boot directory; 4) and copy it to / Boot directory; 5) Modify lilo.conf file, join: image = / boot / zimage label = newlinux root = / dev / hda1 (according to the original file) Run / sbin / lilo makes the modification take effect. 6) Restart, when LILO, enter newlinux can start up. 90. What is a dynamic kernel module? The dynamic kernel module is a successful design of Linux, which makes Linux more flexible and easy to customize. In fact, the dynamic kernel module is a kernel module that dynamically adds some functions to the kernel with the "Insmod Module Name" command without recompiling the kernel, and removes the kernel with the "RMMOD Module Name" command. Six, cheap network solutions --- Linux: 9 Q 91. How to use Linux to set up a web server? The Apache server is the first choice for setting up a web server in Linux. You can choose to install it when you install Linux. If you do not install Apache when installing, you can find a file from the disc or on the Apache website: Apache-1.3.12.i386.rpm, then perform the following command to complete the installation: 1) rpm -ivh apache-1.3.12.i386 .rpm 2) Modify the configuration file httpd.conf, access.conf, access.conf, etc. in the / etc / httpd / conf directory; 3) Place the home page file in / home / httpd / html directory; 4) Execute "/ etc / rc. D / init.d / httpd start "Start the Apache server If you need to close, you can execute the /etc/rc.d/init.d/httpd stop command. 92. How do I use the Linux to set up the FTP server? In Linux, the most commonly used FTP service software is a number of wu-ftpd if it is not installed when it is installed. You can get its RPM package from the CD or website rpmfind.net/linux/rpm/wbyname.html: wu-ftpd-2.6.0-9.i386.rpm. Then do the following command to complete the installation: rpm -ivh wu-ftpd-2.6.0-9.i386.rpm Edit "/etc/inetd.conf" file, point to the new FTPD daemon, as follows: ftp stream TCP NOWAIT ROOT / usr / sbin / tcpd in.ftpd -l -a to this, your Linux can accept FTP service.
93. How do I use the Linux e-mail server? In Linux, the most commonly used E-mail server is Sendmail, you can select it when you install Linux. 1) Do a MX record for the E-mail server on the DNS server; 2) Edit the /etc/inetd.conf file, remove the annotation of the row of POP and SMTP; 3) Execute the kill -hup inetd to make the modification take effect The user of the e-mail server can send and receive mail through client programs such as Outlook. 94. How do I use the Linux to set up the NEWS server? When installing Linux, select the INN package and allow the InND when booting. Most of the configuration work has been completed when the system is installed, and there is no need to compile the source code. 1) Configuration /etc/news/inn.conf: domain: foo.com Organization: Foo Company News Site Server: Localhost fill in according to the actual situation; 2) Configuration /etc/news/nnrp.access nnrp.access is used to complete news The Readers service's waiter NnRPD configuration file is used to control access to the site, modify this file does not have to start InND. 3) Add newsgroup: You can use the ctlinnd command to increase by manually editing / var / lib / news / Active file. If the news group is modified manually, the following command must be executed to take effect: CTLinnd Reload Active "Modify Active" 95. How to use Linux to set up BBS? 1) Download PowerBBS source code release package file pbbs.tar.gz; 2) Execute TAR ZXVF PBBS.TAR.GZ until the file; 3) Enter the PBBS directory, run install; 4) Change the default settings according to the specific requirements. 96. How to make Linux a file server? In Linux, you can use Samba to make a file server, you can select Samba when you install Linux, you can complete the installation. 1) edit /etc/smb.conf, modify the configuration:. Netbios name = linux workgroup = SambaServer server string = Samba Server hosts allow = 192.168.9 127. securoty = share interfaces = 192.168.9.1 / 24 name resolve order = host dns Bcast Wins Support = NO 2) Restart SMB Server: /etc/rc.d/init.d/smb restart 3) Edit client's HOSTS file, join the resolution of Samba Server; 4) You can nearest online I saw it.
97. How do I use the Linux to set up a proxy server? 1) Download Squid Proxy Server Software Squid-2.2.stable3-src.tar.gz; 2) Execute Tar Xzxf Squid-2.2.stable3-src.tar.gz 3) Execute Make, make install installation. / usr / local / squid directory; 5) Edit /usR/local/squid/squid.conf file, join: acl allowed_hosts src 192.168.9.0/255.255.255.0 Note: Suppose your intranet IP address is 192.168.9.0; 6) Execute / usr / local / squid / bin / squid -z for initialization 7) Execute / usr / local / squid / bin / Squid Open Service 8) You can access the Internet on the client settings proxy server IP and port 3128. . 98. How to use Linux to make a transparent gateway? Confirm that the Linux kernel has supported ipchain, then write a script ipchains.rule, the content is: Note: Suppose the external network address of the transparent gateway server is: 1.2.3.4, has been connected to the Internet; the intranet address is 192.168.9.1, Online.