The znew utility uncompresses files compressed by compress and recompresses them with gzip. These files normally have an extension of “.Z”. These files are then re-compressed with an extension of “.gz”. The znew utility tries to maintain the file mode of the original file. If the original file is not writable, it is not able […]
Archives for August 2021
dmesg Command Examples in Linux
The dmesg command is a great command for troubleshooting hardware issues. When a system initially boots, the kernel will identify the various hardware devices available to that system. As the kernel identifies these devices, the information is written to the kernel’s ring buffer. This ring buffer is essentially an internal log for the kernel. The […]
passwd Command Examples in Linux
The passwd command is used to either set the user’s initial password or modify the user’s existing password. The syntax of the passwd command is as follows: $ passwd [username] The root user can set the password for any user to any value without knowing his current password. As a regular user, simply type the […]
Basic NFS Security – NFS, no_root_squash and SUID
I have come across many wide-open NFS servers, which could be made a little more secure and safer with a couple of quick changes. This is a quick, make things a bit more secure guide. This is by no means a complete guide for securing NFS, but it can make things a little more secure […]
logger Command Examples in Linux
logger command is used to log messages in the system log or syslog. You can log a messages string on the command line or provide a file as input that can contain the message to be logged. To view the available switches for the logger command: # logger –help Usage: logger [options] [message] Options: -T, […]
What is ioremap()
ioremap() function is used to map the physical addres of an I/O device to the kernel virtual address. Kernel creates a page table i.e mapping of virtual address to the physical address requested.When we do iounmap() this mapping is destroyed. The ioremap function takes two parameters: start of the memory region size of the memory […]
Linux Network File System (NFS) interview questions
What is NFS? Network File System (NFS) is one of the oldest computer file sharing products in existence today. It is still the most popular for sharing directories of files between UNIX and Linux systems. NFS allows servers to designate specific directories to make available to designated hosts and then allows client systems to connect […]
lvchange Command Examples in Linux
lvchange command changes LV attributes in the VG, changes LV activation in the kernel and includes other utilities for LV maintenance. For example, you may use lvchange while removing a disk from a Volume Group. Below outlined steps, provide a procedure to remove a disk from VG. Note: Backup the whole Volume Group either by […]
lvremove Command Examples in Linux
Deleting a volume frees its storage back to the volume group, which can then be used to create new logical volumes or support growing an existing volume. lvremove command can be used to delete an LVM volume which we no longer intend to use. Please make sure you take a backup of the mount point […]
What are sparse files in Linux
Have you ever obeserved difference in disk usage of some file while using du and ls command. For example: $ du -sh /u02/ticoprd/redo/* 515M redo1a.rdo 524M redo3b.rdo 518M redo4a.rdo $ ls -ltrh /u02/ticoprd/redo/* -rw-r—– 1 oticoprd dba 1.1G Aug 4 01:09 redo1a.rdo -rw-r—– 1 oticoprd dba 1.1G Aug 4 02:32 redo3b.rdo -rw-r—– 1 oticoprd dba […]