Birmingham mumbai



Download 15,21 Mb.
Pdf ko'rish
bet239/482
Sana13.01.2022
Hajmi15,21 Mb.
#355107
1   ...   235   236   237   238   239   240   241   242   ...   482
Bog'liq
Mastering Ubuntu Server Gain expertise in the art of deploying, configuring, managing, and troubleshooting Ubuntu Server by Jay LaCroix (z-lib.org)

[
 180 
]
The name of the unit doesn't really matter, as the syntax of the 
systemctl
 command 
is the same regardless of the name of the unit we're interacting with. You can use 
systemctl
 to start, stop, or restart your Apache instance, your database server, or 
even use it to restart the entire networking stack. The 
systemctl
 command, with no 
options or parameters, assumes the 
list-units
 option, which dumps a list of units to 
your shell. This can be a bit messy, though, so if you already know the name of a unit 
you'd like to search for, you can pipe the output into 
grep
 and search for a string. 
This is handy in a situation where you may not know the exact name of the unit, but 
you know part of it:
systemctl |grep ssh 
If you want to check the health of a unit, the best way is to actually use the 
status
 
keyword, which will show you some very useful information regarding the unit. 
This information includes whether or not the unit is running, if it's enabled (meaning 
it's configured to start at boot time), as well as the most recent log entries for the unit:
systemctl status ssh 
This command will produce an output something like the following:
Figure 7.9: Checking the status of a unit with systemctl
Most of the time, you can actually check the status of units without needing 
root
 
access, but you may not see all the information available. In the screenshot, you can 
see several log entries for the 
ssh
 service, but some units do not show those entries 
without 
sudo
. With the 
ssh
 unit in particular, we see the log entries when checking 
the status with or without 
sudo
.


Chapter 7

Download 15,21 Mb.

Do'stlaringiz bilan baham:
1   ...   235   236   237   238   239   240   241   242   ...   482




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©hozir.org 2024
ma'muriyatiga murojaat qiling

kiriting | ro'yxatdan o'tish
    Bosh sahifa
юртда тантана
Боғда битган
Бугун юртда
Эшитганлар жилманглар
Эшитмадим деманглар
битган бодомлар
Yangiariq tumani
qitish marakazi
Raqamli texnologiyalar
ilishida muhokamadan
tasdiqqa tavsiya
tavsiya etilgan
iqtisodiyot kafedrasi
steiermarkischen landesregierung
asarlaringizni yuboring
o'zingizning asarlaringizni
Iltimos faqat
faqat o'zingizning
steierm rkischen
landesregierung fachabteilung
rkischen landesregierung
hamshira loyihasi
loyihasi mavsum
faolyatining oqibatlari
asosiy adabiyotlar
fakulteti ahborot
ahborot havfsizligi
havfsizligi kafedrasi
fanidan bo’yicha
fakulteti iqtisodiyot
boshqaruv fakulteti
chiqarishda boshqaruv
ishlab chiqarishda
iqtisodiyot fakultet
multiservis tarmoqlari
fanidan asosiy
Uzbek fanidan
mavzulari potok
asosidagi multiservis
'aliyyil a'ziym
billahil 'aliyyil
illaa billahil
quvvata illaa
falah' deganida
Kompyuter savodxonligi
bo’yicha mustaqil
'alal falah'
Hayya 'alal
'alas soloh
Hayya 'alas
mavsum boyicha


yuklab olish