Download the document from ftp://instructor.example.com/pub/testfile, find all lines containing [abcde] and redirect to /MNT/answer document, then rearrange the order according the original content.
Solution:
see explanation below.
Download the file to /tmp first
grep [abcde] /tmp/testfile > /mnt/answer
Does this meet the goal?
Correct Answer:
A
Add users: user2, user3.
The Additional group of the two users: user2, user3 is the admin group Password: redhat
Solution:
# useradd -G admin user2
# useradd -G admin user3
# passwd user2
redhat
# passwd user3
redhat
Does this meet the goal?
Correct Answer:
A
Part 2 (on Node2 Server)
Task 2 [Installing and Updating Software Packages]
Configure your system to use this location as a default repository: http://utility.domain15.example.com/BaseOS
http://utility.domain15.example.com/AppStream
Also configure your GPG key to use this location http://utility.domain15.example.com/RPM-GPG-KEY-redhat-release
Solution:
[root@node1 ~]# vim /etc/yum.repos.d/redhat.repo
[BaseOS]
name=BaseOS
baseurl=http://utility.domain15.example.com/BaseOS
enabled=1
gpgcheck=1
gpgkey=http://utility.domain15.example.com/RPM-GPG-KEY-redhat-release
[AppStream]
name=AppStream
baseurl=http://utility.domain15.example.com/AppStream
enabled=1
gpgcheck=1
gpgkey=http://utility.domain15.example.com/RPM-GPG-KEY-redhat-release
[root@node1 ~]# yum clean all
[root@node1 ~]# yum repolist
repo id repo name
AppStream AppStream
BaseOS BaseOS
[root@node1 ~]# yum list all
Does this meet the goal?
Correct Answer:
A
/data Directory is shared from the server1.example.com server. Mount the shared directory that:
Solution:
* 1. vi /etc/auto.master
/mnt /etc /auto.misc --timeout=50
vi /etc/auto.misc
data -rw,soft,intr server1.example.com:/data
service autofs restart
chkconfig autofs on
When you mount the other filesystem, you should unmount the mounted filesystem, Automount feature of linux helps to mount at access time and after certain seconds, when user unaccess the mounted directory, automatically unmount the filesystem.
/etc/auto.master is the master configuration file for autofs service. When you start the service, it reads the mount point as defined in /etc/auto.master.
Does this meet the goal?
Correct Answer:
A
Set cronjob for user natasha to do /bin/echo hiya at 14:23.
Solution:
# crontab -e -u natasha
23 14 * * * /bin/echo hiya
wq!
Does this meet the goal?
Correct Answer:
A