Shutdown Linux after pre-determined time

This is an alternative for Cron Issue the following command in terminal: /sbin/shutdown -h +300 Command Details: sudo : This is to execute the command as root, you will need the password here. /sbin/shutdown : Command to shutdown the computer. -h : This tell the shutdown command to power off i.e. halt. +300 : The … Read more

Network printers

By tradition in Unix most services come with networking capabilities. This includes the printing server. You don’t need to get third party software to make a printing server. The lpd daemon allows you to print to your local printer, but also allows others to print on it, if you allow them. By default the printing … Read more

Who owns this port

Several utilities exist to check which ports are open, who is connected to your system and even what process owns a port number. First a few ground rules. Ports below 1024 are reserved for common services, and only root can use them. Standard port numbers can be found in /etc/services. The maximum number of ports … Read more

Names and name servers

Internet hostnames and domains are resolved using the Domain Name System (DNS) using Name Servers (NS). These name servers are usually hosted by your Internet provider. You can also host your own name server, using the program named. Every name server, upon receiving a request to resolve a hostname, will ask an upstream name server … Read more

Secure alternative to telnet

Secure alternative to telnet Telnet is a protocol allowing you to connect to a remote system and run programs and commands on that system. It is very old and still very much in use today. Unfortunately, a telnet client sends the user password as clear text, and the connection is not encrypted. On the other … Read more

Accessing remote file systems

Accessing remote file systems SMB is the most popular protocol to access Windows systems. But from the Unix world comes NFS. NFS is a way to share files that predates SMB and Samba, and comes compiled in most Linux distributions. To enable file sharing, you must have the nfsd and mountd daemons running. You also … Read more

Access to various networks

Big corporations often sub-divide their networks into small networks, hidden behind gateways. To access them, you need to tell your Linux system that there is a gateway to use to access the networks. The route program makes it easy to add networks, hosts and gateways to your routing table. To add a default gateway, for … Read more

Reading a foreign file system

File systems are defined in the kernel. The kernel supports many file systems, but they need to be compiled in, or compiled as a module. When you compile a file system in the kernel, all you need to do is use mount with the -t option and the right file system type. If you have … Read more

Detecting 2 ethernet cards

To configure an ethernet card in Linux, you need to enable it in the kernel. Then the kernel will detect your ethernet card if it is at a common IO port. But it will stop there, and will never check if you have 2 ethernet cards. The trick is to tell the ethernet driver that … Read more