Hardware and Kernel Insigths uname -m # Display the system's CPU architecture uname -r # Output the active kernel release string dmidecode -q # Extract SMBIOS/DMI hardware component data hdparm -I /dev/sda # Retrieve detailed characteristics of a storage device hdparm -tT /dev/sda # Execute read-spe...
Toggling and Managing Internal Commands Internal shell commands can be disabled or enabled dynamical. Use enable -n to turn off a built-in and enable to restore it. [root@localhost opt]# enable -n cd [root@localhost opt]# cd /mnt/ [root@localhost opt]# After disabling cd, the command no longer funct...
Batch File Processing Example #!/bin/bash python preprocess_annotation.py -i wheat_annotation.gff3 -o wheat_annotation_filtered.gff4 base_fasta="wheat_transcripts.fasta" annotation_gff="wheat_annotation_filtered.gff4" motif_types=("G4" "C4" "A4" &quo...
Automated Service Startup with Password Authentication The following expect script handles services requiring sudo access: #!/usr/bin/expect set timeout 5 spawn mysql.server start echo "MySQL service started successfully" spawn sh /opt/app/tomcat/bin/shutdown.sh spawn sh /opt/app/tomcat/bi...