Disk Space Upgrade UNIX Filesystem Layout

vnode does not have anything common with inode except that the names sound similar. These are two completely different concepts, with different purposes. vnode is mostly unknown to UNIX administrators and is not even mentioned in system administration books. There are at least two good reasons for that. The first reason was discussed earlier, while the second one is based on the assumption that VFS will not require any administration — everything should work well automatically. Despite that, VFS is briefly discussed here.

6.4 Disk Space Upgrade

Once a shortage of a disk space becomes evident on the system and all other possibilities have been exhausted, the only real solution is to add a new disk. Today, disks are cheap, and to make such a decision is easy. However, the full price of additional disk space includes other elements besides the disk price itself. In the past additional expenses have been mostly shadowed by the high disk price. Some elements worth consideration are: The room available for disks — internal or external • Hardware compatibility — implemented disk interface. On the UNIX platform, SCSI interface is very common, but remember that single−ended SCSI is not compatible with the differential one, or it could be a wide SCSI, or…. Also, is there a slot available on the existing SCSI controller? And so on. • The work on the disk installation and putting it into the operation • Maintenance, including backup and other long−term disk−related jobs • Each of these elements has its specific price. In most cases, this price is higher than the initial price of the disk itself. Adding a new disk is a very routine task. There is not a lot of freedom in the practical implementation, but it is good to fully understand each of the required steps. Unfortunately, almost every UNIX platform provides a different tool to implement these steps. We have already discussed some of these steps. This time we will only list them. Steps traditionally required to add a disk, independent of the UNIX platform even independent of the UNIX itself, may be summarized as: Disk formatting also known as low, or hard, formatting to establish the track layout onto the contiguous magnetic media of the disk plates • Disk partitioning to establish one or more independent storage entities within the disk for further processing • 167 The LVM requires a few more steps before filesystem creation. UNIX systems require some additional steps at the end to merge newly created filesystems into the overall UNIX tree hierarchical filesystem. Today, manufacturers of disks also perform the hard formatting of the disks. There are many reasons for this first step to be performed by the manufacturers themselves; the number of tracks varies among the inner and outer disk cylinders, and an appropriate hard formatting requires the sophisticated tools. While we can skip the first step now, the other steps must be provided. Unfortunately, the required procedures vary among UNIX vendors. In Chapter 27, a few case studies about the most popular UNIX flavors are presented. Similar procedures can be implemented on other UNIX platforms. 168

Chapter 7: User Account Management

7.1 Users and Groups

Managing user accounts is an important and unavoidable administrative duty. The overall system administration will often be evaluated by the way the user accounts are managed. Users participate in a UNIX system through their accounts: they navigate through their environment, work from their terminals, use their favorite commands, and do their jobs in their way. They want to control their resources and restrict access to them by others; however, they also want to reach all available resources. This is a profile of an average user on an UNIX system. UNIX systems exist to be used by users; making users happy is one of the primary administrative tasks, because happy users make for a happy administrator. The advice is very simple: manage user accounts properly, be tough when necessary and flexible at other times, and pay special attention to security issues, or you could experience a lot of headache later. From the systems standpoint, a user is not necessarily an individual. A user is any entity capable of executing programs or own files. The UNIX concepts of ownership and access privileges involve a number of system entities. These entities may be other computer systems, they may be particular system functions that run automatically, or they may be a group of people with similar functions. In most cases, however, a user is a particular individual who can log−in, edit files, run programs, and otherwise make use of the system. Each user has a username also known as a loginname that uniquely identifies the user. A system recognizes a user by the users identification number UID, which is assigned by the system administrator at the time the users account is created. The administrator also assigns each new user to at least one group a group is a collection of users who generally share similar functions. Each group has a group identification number GID, which serves the same purpose as the UID on the user level. Together, the users UID and GID determine the users credentials, i.e., the access rights a user has to files and other system resources. Basic user account information is stored in the etcpasswd file — this is the master users database for all users on the system. The etcpasswd file is an ASCII text file, readable by everyone on the system; this general file readability is required for regular system operations. Each user is described by a single entry in the file; each entry is a single line of information. Similarly, information about groups are stored in the file etcgroup. These two files contain comprehensive information about any user in the system, regardless of the users origin. Both files are public information; everyone may read them, but only the superuser is allowed to modify them.

7.1.1 Creation of User Accounts

You must create a new user account to add a new user to the system. User account creation is a routine procedure that consists of several mutually related steps; most of these steps are mandatory, but a few are optional. The required procedure consists of: Assigning a username, a user ID number, and a primary group to the user • Entering this data in the system user database the etcpasswd file and, if required, in any secondary password file • Assigning a password to the new account • Setting other user account parameters in use on the system, such as password aging, account expiration date, and other resource limits • 169