1/160
Looks like no tags are added yet.
Name | Mastery | Learn | Test | Matching | Spaced |
---|
No study sessions yet.
While using the BASH, which of the following commands will switch the default display in such a way that new applications will appear on the remote machine 192.168.1.50?
A. display 192.168.1.50
B. export DISPLAY=192.168.1.50
C. export TARGET=192.168.1.50
D. switch 192.168.1.50
B. export DISPLAY=192.168.1.50
Which of the following commands will display a user's current environment variables? (Select TWO)
A. env
B. info env
C. displayenv
D. man env
E. printenv
A. env & E. printenv
Which of the following is the default location of the Xorg configuration file?
A. /etc/X11/xorg.conf
B. /etc/X11/X.conf
C. /etc/X/xorg.conf
D. /etc/Xorg/X.conf
A. /etc/X11/xorg.conf
Which of the following commands will explicitly start a full X windows system session?
A. startx
B. xinit
C. X
D. startX
A. startx
After installing and enabling the latest accelerated video card driver, the system fails to start the X Window System on a reboot. Which of the following drivers is MOST likely to allow the system to start the GUI?
A. vesa
B. vega
C. xorg
D. krfb
A. vesa
Which of the following commands will cause gedit to use workstation1 for I/O?
A. DISPLAY=workstation1 gedit
B. CONNECT=workstation1 gedit
C. GRAPHICS=workstation1 gedit
D. CONSOLE=workstation1 gedit
A. DISPLAY=workstation1 gedit
Which of the following commands will show status information of the print queues?
A. lpstatus
B. showprint
C. lpqueue
D. lpstat
lpstat
Where is the default location of sendmail binary?
A. /usr/lib/sendmail
B. /etc/mail/sendmail
C. /var/spool/sendmail
D. /sbin/sendmail
A. /usr/lib/sendmail
Which of the following files holds information on the system's time zone?
A. /etc/timezone
B. /etc/localtime
C. /etc/time
D. /etc/localzone
B. /etc/localtime
Which of the following commands will show active network connections?
A. ipstat
B. ifstat
C. netstat
D. networkstat
C. netstat
A user has inserted a USB drive but it has not been automatically mounted. Which of the following commands will show the device name of the USB drive?
A. mount -t usb
B. fdisk -l
C. usb_scan
D. partprobe
B. fdisk -l
Which of the following will burn an ISO image to a writable SCSI CD-ROM drive located on SCSI address 0,1,0?
A. cdrecord -v -eject dev=0,1,0 data.iso
B. cdrecord -t scsi -eject -d=0,1,0 data.iso
C. cdrecord dev=0,1,0 -t=data.iso
D. cdrecord -V -dev 0,1,0 -eject data.iso
A. cdrecord -v -eject dev=0,1,0 data.iso
Which of the following /etc/fstab entries represents a Read-Write file system that can be mounted by any user?
A. /dev/hdc1 /data ext3 noauto,users 0 0
B. /dev/hdc1 /data auto defaults 0 0
C. /dev/hdc1 /data auto noauto,user 0 0
D. /dev/hdc1 /data ext3 defaults 0 0
A. /dev/hdc1/data ext3 noauto,users 0 0
A technician wants to upgrade an existing package to a new software package called software.rpm. Which of the following commands will accomplish this?
A. rpm -el ./software.rpm
B. rpm -Ve ./software.rpm
C. rpm -ieh ./software.rpm
D. rpm -Uvh ./software.rpm
D. rpm -Uvh ./software.rpm
Which of the following is the correct way to upgrade an existing software package using yum?
A. yum new package
B. yum get package
C. yum retrieve package
D. yum update package
D. yum update package
Which of the following key commands in vi allows a technician to append to the current line?
A. A
B. aa
C. p
D. a
A. A
Which of the following commands will replace the first instance of the string "linux" to "Linux" in the text file called history.txt and outputs the results to standard output?
A. sed r/linux/Linux/ history.txt
B. sed g/linux/Linux/ history.txt
C. sed s/linux/Linux/ history.txt
D. sed w/linux/Linux/ history.txt
C. sed s/linux/Linux/ history.txt
Which of the following symbols redirects standard output?
A. <
B. =
C. &
D. >
D. >
Which of the following commands will allow an administrator to change the priority of a running process?
A. bg
B. pstree
C. renice
D. fg
C. renice
Which of the following is the BEST way to direct the standard output of a program to both the screen and a file at the same time?
A. cat
B. tee
C. redirection (>)
D. echo
B. tee
If you want to change profiles for all users on the system.
/etc/profile and /etc/bashrc
When the user logins in, specific user.
.bash_profile
When the user starts a new shell, specific user.
.bashrc
How to unassign the variable COLOR?
unset COLOR
To see all the functions on your system?
set
Which file specifies the environment variables to be set.
/etc/security/pam_env.conf
If you want a new file to be created when a new user is created, where do you put it ?
/etc/skel
Which file that specifies the skeleton file, the shell and the default home when a new user is created?
/etc/default/useradd
Where is the printer queue stored ?
/var/spool/cups
How can you configure cups graphically?
http://localhost:631/
Two most important files for configuring cups?
/etc/cups/printers.conf & /etc/cups/cupsd.conf
how to add a printer?
lpadmin -p printername -E -v device -m name_of_ppd
show available devices for a printer?
lpinfo -v
make a default printer
lpadmin -d textprinter
To print something?
lpr -Ptextprinter file_to_print
Configuring a Text Only Printer
$ lpadmin -p textprinter -m textonly.ppd
what is happening in the queue ?
$ lpq -Ptextprinter
To remove the last printer job
lprm
To remove all the printer jobs
lprm -
log files for cups ?
/var/logs/cups/error_log & /var/logs/cups/access_log
How to disable and enable printers?
cupsdisable dummyprinter
cupsenable dummyprinter
command allows a user to administer his/her own group
membership list without the requirement of superuser privileges.
groupmems
How to find files that has SUI set.
$ find / -perm /4000
To scan the entire network using nmap
nmap 8.8.8.8/24
which file can you limit the number of processes for a user or group?
/etc/security/limits.conf
which show you when is the last time a user has logged into or never logged into the system.
lastlog
which old method to allow and deny hosts?
/etc/hosts.allow & /etc/hosts.deny
$ ls -lZ
this will show if the file is handled under selinux
How to search for SElinux related issues in the logs?
$ grep AVC | /var/log/audit/audit.log
Which command you can use to schedule a job at a later time, just once?
at 9:30 PM Tue
warning: commands will be executed using /bin/sh
at> echo "Well gosh golly, it's 9:30 PM on Tuesday."
at> ^D
Which file you can use to schedule cron jobs?
/etc/crontab
What is the format of the lines in /etc/crontab?
* user command
min hour day mon dow
files to allow users to user or not to use at or cron?
/etc/at.deny
/etc/at.allow
/etc/cron.deny
/etc/cron.allow
What can schedules job within a specific time frame?
/etc/anacrontab
what is the most trusted stratum number?
ntp uses stratum (highest trusted in stratum 1).
how to set date?
date -s 9:15
or
timedatectl set-time 9:15
how to synchronize hardware and system clock?
$ hwclock --hctosys
$ hwclock --systohc
which file that you can check for zone information?
/usr/share/zoneinfo
log files are typically stored where?
/var/log
what service will allow you to take care of when logs are deleted and stuff like that ?
/etc/logrotate.conf
where is the syslog confiigration file?
/etc/rsyslog.conf
Not every service logs to syslog.
local1-7 is used for that service.
Apache and Samba are among those servers.
Apache: Errorlog syslog:local1
new logging system for systemd systems.
journald and works hand in hand with rsyslog
journalctl
bring a network interface up or down
ifconfig enps035 down
assign an interface ip address or netmask
ifconfig enps035 192.168.1.100
ifconfig enps3045 netmask 255.255.0.0
most important file for network configuration
/etc/sysconfig/network-scripts
On Debian systems:
/etc/network/interfaces
show interfaces status
ip link show
or
ip addr show
static ip addressing or dhcp
BOOTPROTO = none or dhcp
Configuring Client Side DNS
/etc/resolv.conf
Received mail goes to
/var/spool/mail
Create E-mail Aliases
/etc/aliases
and exectue:
$ newaliases
so the changes take effect.
important file to configure email
/etc/postfix/master.cf
/etc/postfix/main.cf (queue directory where the messages will be stored).
what to do for email forwarding
set relayhost ip address in /etc/postfix/main.cf
configure ssh server
/etc/ssh/sshd_config
important options for ssh configuration
PermitRootLogin yes
PasswordAuthentication yes
X11Forwarding yes
UseDNS no
how to do SSH Tunneling
ssh -L 9000:ismvml61:443 aabdalma@ismnagios
AllowTcpForwarding yes
If you want to secure email messages and file transfers, you should use:
GnuPG
to generate keys:
gpg --gen-key
results will be in stored in: ~/.gnupg directory
gpg.pub
gpg --{sign|clearsign) originalfile
For an increased of security, we use -sign
--armor if you intend to the send the key over by email.
this checks for null. shell script
if [ -z $1 ]
variable that captures all the arguments as one entity?
$*
variable that captures all the arguments as one by one
$@
variable that captures all the number of arugments
$#
variable the capture the return value from a program
$?
send email to the root
[ -e $1 ] || mail -s "$1 does not exist" root < .
The ........ utility is an old utility for keyboard accessibility.
accessx
keyboard tool for GNOME
gok
keyboard tool for KDE
kmag
tool for speech in GNOME
Ocra
what tool covert desktop display to speech
Emacspeak
Tool to help the blind
brltty
to set french:
$ LANG=fr_FR.UTF-8
mysql commands to remember:
mysql_secure_installation
mysql -u root -p
$ create USER julia@'%' IDENTIFIED BY 'secret';
$ GRANT SELECT,INSERT,UPDATE, DELETE on videos.* TO julia@'%';
$ FLUSH PRIVILEGES;
how to initialize an X session
startx
which command to configure X?
$ Xorg -configure
Where do video drivers reside?
/usr/X11R6/lib/modules/drivers
or
/usr/lib/xorg/modules/drivers
command to set resolution
xrandr
too much information about X
xdpyinfo
information about current settings and positioning of an X window.
xwininfo
where the fonts at?
/usr/share/fonts
/usr/share/X11/fonts
fast and lightweight display manager.
lightdm
/usr/share/lightdm/lightdm.conf.d
index file for fonts in the current directory
mkfontscale
mkfontdir