UNIX / Linux command-line interface.

Upgrading Red Hat Enterprise Linux / CentOS

RHEL/CentOS 5–6–7 Migration: Storage

The default file system has changed multiple times, going from Ext3 to Ext4 to XFS, and possibly on to Btrfs in some distributions. Given a recent enough kernel and user-space tools, you could have used later file systems in some releases, and you still have full backward-compatable support of all older file systems. The file /etc/fstab has become less complex with the kernel automatically mounting many of the pseudo file systems without them being explicitly listed.

Previous: Users and Groups,
Identity Management

The previous page described the relatively minor changes in user and group management. Now that we have created these user accounts, we must set up storage for all their data!


5 — Storage

The default file system has changed twice in going from RHEL 5 (Ext3) to RHEL 6 (Ext4) to RHEL 7 (XFS).

Release Default FS Maximum
Volume size File size
RHEL 5 Ext3 4–32 TiB 16 GiB – 2 TiB
RHEL 6 Ext4 1 EiB 16 TiB
RHEL 7 XFS 16 EiB 8 EiB
RHEL ? Btrfs 16 EiB 8 EiB

1 TiB = 240 bytes = 1024 GiB
1 PiB = 250 bytes = 1024 TiB
1 EiB = 260 bytes = 1024 PiB

Release Default FS File System Tools
Create Modify/view
metadata
Modify/grow
file system
Check/Repair Dump
Restore
RHEL 5 Ext3 mkfs.ext3 tune2fs
dumpe2fs
resize2fs fsck.ext3 dump
restore
RHEL 6 Ext4 mkfs.ext4 tune2fs
dumpe2fs
resize2fs fsck.ext4 dump
restore
RHEL 7 XFS mkfs.xfs xfs_admin xfs_growfs xfs_repair xfsdump
xfsrestore
RHEL ? Btrfs mkfs.btrfs btrfs filesystem
btrfs-debug-tree
btrfs property
btrfs filesystem btrfs scrub
btrfsck
btrfs rescue
btrfs restore
btrfs image
btrfs image

The kernel drivers used for IDE/PATA disks have changed. IDE/PATA disks appeared as devices /dev/hd? in RHEL 5, starting with RHEL 6 all disks are /dev/sd?.

File system device definitions in /etc/fstab were in terms of LABEL= in RHEL 5. That changed to UUID= in RHEL 6.

Starting with RHEL 7, it is no longer practical for /usr to be a separate file system. This isn't specifically the fault of RHEL, it's that the components used by all distributions now disregard or violate the old convention that the root file system be small with just what's needed for booting while /usr has things needed later. But now /bin, /lib, /lib64 and /sbin are just symbolic links to directories within /usr.

Red Hat's recommendation for swap area continues to change and contradict itself. For example, install RHEL 7 onto a system with 8 GB of RAM and let the installer set up the storage. Red Hat's documentation recommends either 4 or 8 GB in that situation, but their installer creates a 2 GB swap area.

It's time to kill off the old assumptions about Oracle needing unusual amounts of swap and a raw partition of its own. Put Oracle on a modern system with plenty of RAM and an efficient file system.

The NFS server now uses /etc/exports.d/* in addition to /etc/exports.

The automounter now uses /etc/auto.master.d/* in addition to /etc/auto.master.

The mount command shows an ever-larger list of mounts that aren't file systems appearing in routine df output. They do appear if you run df -a.

However, at least the /etc/fstab file is much simpler in RHEL 7.

Release Physical
RAM
Swap
Recommendation
To allow
hibernation
RHEL 4 always at least 32 MB
≤ 2 GB 2 × RAM
> 2 GB 2 GB + RAM
RHEL 5 < 4 GB at least 2 GB
4–16 GB 4 GB
16–64 GB 8 GB
64–256 GB 16 GB
256–512 GB 32 GB
RHEL 6 ≤ 2 GB 2 × RAM 3 × RAM
2–8 GB same as RAM 2 × RAM
8–64 GB at least 4 GB 1.5 × RAM
> 64 GB at least 4 GB don't
RHEL 7 ≤ 2 GB 2 × RAM 3 × RAM
2–8 GB same as RAM 2 × RAM
8–64 GB 0.5 × RAM 1.5 × RAM
> 64 GB it depends don't

These lines were in /etc/fstab in RHEL 5 and 6. The lines are gone in RHEL 7. The file systems are now mounted automatically by the kernel, they don't clutter up /etc/fstab:

none  /dev/pts  devpts  gid=5,mode=620  0 0
none  /dev/shm  tmpfs   defaults        0 0
none  /proc     proc    defaults        0 0
none  /sys      sysfs   defaults        0 0 
Next: Software Packages

Now that we can add storage as needed, we can start some large software development projects. The next page combines two related topics: package management with rpm and yum, and building software from source.

Next: Software Packages