Professional Documents
Culture Documents
Contact Details
Name : Mehul Solanki
Phone : +919879729795
Email : er.mehulsolanki1887@gmail.com
LinkedIn : https://in.linkedin.com/in/mehulsolanki1887
IP ADDRESS = 172.25.250.10
NETMASK = 255.255.255.0
GATEWAY = 172.25.250.254
DNS/NameServer = 172.25.250.254 (Auto Off)
hostname = servera.lab.example.com
OR
Step 1 : [root@servera ~]# nmcli connection show
Step 2 : [root@servera ~]# nmcli connection delete ens160
Step 3 : [root@servera ~]# nmcli connection add type ethernet con-
name ens160 ifname ens160
Step 4 : [root@servera ~]# nmcli connection modify "ens160"
ipv4.addresses 172.25.250.10/24
Step 5 : [root@servera ~]# nmcli connection modify "ens160"
ipv4.gateway 172.25.250.254
Step 6 : [root@servera ~]# nmcli connection modify "ens160"
ipv4.dns 172.25.250.254
Step 7 : [root@servera ~]# nmcli connection modify "ens160"
ipv4.method static
Step 8 : [root@servera ~]# nmcli connection modify ethernet-ens160
ipv4.method auto
Step 9 : [root@servera ~]# nmcli connection up ens160
Step 10 : [root@servera ~]# nmcli device status
Step 11 : [root@servera ~]# hostnamectl set-hostname
servera.lab.example.com
[BaseOS]
name = BaseOS
baseurl = http://content.example.com/rhel8.0/x86_64/dvd/BaseOS
enabled = 1
gpgcheck = 0
[AppStream]
name = AppStream
baseurl = http://content.example.com/rhel8.0/x86_64/dvd/AppStream
enabled = 1
gpgcheck = 0
● A web server running on non-standard port 82 is having issues serving content. Debug and
fix issues.
● The web server on your system can server all the existing HTML files from
/var/www/html (NOTE: Do not make any changes to these files).
● Web service should automatically start at boot time.
● (a)All new creating files for user natasha as -r-------- as default permission.
● (b) All new creating directories for user natasha as dr-x------ as default permission.
Step 2 : esc:wq
(For Group)
(For User)
● Configure a cron job that runs every day at 12:23 and executes.
Step 10 : timedatectl
● while you are able to log in as any of the user ldapuser1 through ldapuser20, the only home
directory that is accessible from your system is ldapsuser2.
● Copy the file /etc/fstab to /var/tmp/ and configure the "ACL" as mentioned following.
● The file /var/tmp/fstab should be owned by the "root".
● The file /var/tmp/fstab should belong to the group "root".
● The file /var/tmp/fstab should not be executable by anyone.
● The user "natasha" should be able to read and write to the file.
● The user “sarah" can neither read nor write to the file.
● Other users (future and current) should be able to read /var/tmp/fstab.
14. LOCATE ALL FILES OWNED BY USER "HARRY " AND COPY
UNDER /ROOT/HARRY-FILES.
• Locate all files owned by user "harry " and copy it under /root/harry-files.
• Find a string 'ich' from " /usr/share/dict/words " and put it into /root/lines file.
OR
OR
• Example -1
!/bin/bash
• Example -2
#!/bin/bash
Step 1 : reboot
Step 2 : press “e” at kernel option (On Rescue Mode)
Step 3 : type rd.break at last of the line which is start with
linux
Step 4 : Ctrl + x
Step 5 : mount -o remount,rw /sysroot
Step 6 : chroot /sysroot
Step 7 : passwd root
Step 8 : type passwd
Step 9 : touch /.autorelabel
Step 10 : ctrl + d (press twice) OR exit (press two time)
[BaseOS]
name = BaseOS
baseurl= http://content.example.com/rhel8.0/x86_64/dvd/BaseOS
enabled = 1
gpgcheck = 0
[AppStream]
name = AppStream
baseurl = http://content.example.com/rhel8.0/x86_64/dvd/AppStream
enabled = 1
gpgcheck = 0
Step 1 : lsblk
Step 2 : fdisk /dev/vdb
Step 3 : press “n” for new partition
Step 4 : press “p” for primary partition
Step 5 : choose partition default “1”
Step 6 : press enter in first sector
Step 7 : enter size in last sector +512M
Step 8 : press t for assigning type in of partition
Step 9 : press 82 for swap
Step 10 : press “w” for write and save
Step 11 : lsblk (To check created partition)
Step 12 : partprobe /dev/vdb1
Step 13 : mkswap /dev/vdb1
Step 14 : swapon /dev/vdb1
Step 15 : blkid /dev/vdb1 >> /etc/fstab
Step 16 : vim /etc/fstab
UUID=0b9f9c46-35fb-49d5-9f59-8c2e40a6139d swap
swap defaults0 0 (edit entry like this)
Step 17 : mount -a
Step 18 : lsblk (check partition added or not)
└─rhel-swap 253:1 0 1.5G 0 part [SWAP]
Step 1 : df -h
Step 2 : lvdisplay
Step 3 : lsblk
Step 4 : lvextend -r -L 250M /dev/mapper-myvol-mylv
OR
OR
• Create the logical volume with the name "wshare" by using 50PE's from the volume group
"wgroup".
• Consider each PE size of the volume group as "8 MB".
• Mount it on /mnt/wshare with file system vfat.
UUID=0b9f9c46-35fb-49d5-9f59-8c2e40a6139d /mnt/wshare
vfat defaults 0 0(edit entry like this)