SlideShare a Scribd company logo
1 of 31
Download to read offline
CentOS 7 ධ㛛 
᪂䛧䛟⏕䜎䜜ኚ䜟䛳䛯CentOS
⮬ᕫ⤂௓ 
኱ཎ ៅ୍㑻䚷https://twitter.com/ohhara_shiojiri 
䠄᭷䠅䝖䝷䝇䝖䝛䝑䝖䝽䞊䜽䝇䚷ሷᑼ䜲䞁䜻䝳䝧䞊䝅䝵䞁䝥䝷䝄䠍䠌䠔ྕᐊ 
http://shiojiri-osslabo.com/ 
䞉㛗㔝┴ሷᑼᕷ䛻άືᣐⅬ䜢⨨䛟䚸ᕷෆ䝥䝻䜾䝷䝬䞊᭷ᚿ䛻䜘䜛ᅋయ 
䞉䛂䜸䞊䝥䞁䛺⎔ቃ䛷䜸䞊䝥䞁䛺άື䜢┠ᣦ䛩䛃䜢ྜゝⴥ䛻㞟䛖 
䞉CoderDojo Shiojiri 㛤ദ䚷䞉ᑠᏛ⏕㧗Ꮫᖺྥ䛡Rubyᩍᐊ㛤ദ 
䞉ITᢏ⾡᭩䜢䝸䝤䝷䜲䝈䛷㈚䛧ฟ䛧䚸䜎䛯ᕷ❧ᅗ᭩㤋䛸༠ຊ
䜰䝆䜵䞁䝎 
● CentOS䛻䛴䛔䛶 
● RHEL 7 䛻䛴䛔䛶 
● LAMP⎔ቃ䛻䛴䛔䛶 
● 䜲䞁䝇䝖䞊䝹䛻䛴䛔䛶 
● ᳨ド⎔ቃ 
● systemd 
● NetworkManager 
● iproute2
CentOS䛻䛴䛔䛶 
● Red Hat Enterprise Linux(RHEL)䜽䝻䞊䞁 
௚䛻Ꮫ⾡ྥ䛡䛻Scientific Linux 
● RHEL䛛䜙ၟᶆ䜔ၟ⏝䛾䝟䝑䜿䞊䝆䜢㝖እ 
● Community ENTerprise Operating System 
● Red Hat♫䛾᭷ൾ䝃䝫䞊䝖䜢ᚲせ䛸䛧䛺䛔⏝㏵ 
● 2014ᖺ1᭶Red Hat♫䛜ᨭ᥼⾲᫂ 
● RHEL䛸㧗䛔஫᥮ᛶ
RHEL 7 䛻䛴䛔䛶 
● 2014ᖺ6᭶10᪥䝸䝸䞊䝇 
● 10ᖺ㛫䝃䝫䞊䝖䚷2024ᖺ6᭶30᪥䜎䛷 
● Fedora19䜢䝧䞊䝇 
● 䜹䞊䝛䝹䝞䞊䝆䝵䞁 3.10 
● 64bit䛾䜏 x86_64/ppc64/s390s䝃䝫䞊䝖 
● ext4 → xfs䚷᭱኱500TB䝃䝫䞊䝖 
● GRUB Legacy → GRUB2䚷UEFI䝃䝫䞊䝖
LAMP⎔ቃ䛻䛴䛔䛶 
● LAMP⎔ቃ䛸䛧䛶䛾CentOS 
○ ᚑ᮶䝅䝇䝔䝮䛸䛾஫᥮ᛶ䛸Ᏻᐃᛶ䜢㔜ど䛧䛶䚸ᶆ‽䝟䝑 
䜿䞊䝆䛾䝞䞊䝆䝵䞁䛿ྂ䛔䜎䜎䛷䛧䛯䚹 
○ ྂ䛔䝞䞊䝆䝵䞁䛾䝃䝫䞊䝖䛜⥆䚻䛸⤊஢䛧䛶䛔䜛䚹 
○ ᛶ⬟ྥୖ䚸ᶵ⬟ྥୖ䚸䝉䜻䝳䝸䝔䜱ྥୖ䛜ồ䜑䜙䜜䜛䚹 
○ RHEL7(CentOS7)䛛䜙᪂䛧䛔䝞䞊䝆䝵䞁䜢᥇⏝䟿 
● CentOS6.5䛾LAMP⎔ቃ 
○ Apache䚷→䚷2.2.15䚷㛤Ⓨ⤊஢䚷᪂∧⛣⾜䜢᥎ዡ 
○ MySQL䚷→䚷5.1.73䚷㛤Ⓨ⤊஢䚷᪂∧⛣⾜䜢᥎ዡ 
○ PHP䚷→䚷5.3.3䚷㛤Ⓨ⤊஢䚷᪂∧⛣⾜䜢᥎ዡ 
○ Perl䚷→䚷5.10.1 
○ Python䚷→䚷2.6.6
LAMP⎔ቃ䛻䛴䛔䛶 
● CentOS7䛾LAMP⎔ቃ 
○ Apache䚷→䚷2.4.6䚷᭱᪂ᶵ⬟䛾Ᏻᐃ∧ 
○ MySQL䚷→䚷MySQL5.5஫᥮䛾MariaDB 5.5.37 
○ PHP䚷→䚷5.4.16䚷᭱᪂䛾PHP䛿5.6.0 
○ Perl䚷→䚷5.16.3䚷᭱᪂䛾Perl䛿5.20.0 
○ Python䚷→䚷2.7.5䚷᭱᪂䛾Python䛿3.4.1 
○ ྛ䝞䞊䝆䝵䞁䛿2014ᖺ9᭶10᪥᫬Ⅼ䛷䛩䚹 
● CentOS6.5䛷LAMP⎔ቃ䛾᪂䝞䞊䝆䝵䞁ᵓ⠏ 
䛿኱ኚ㠃ಽ䛺䛾䛷䚸CentOS7䜢฼⏝䛧䜎䛧䜗 
䛖䚹 
● CentOS6.5䛛䜙CentOS7䜈䛾⛣⾜䛜බᘧ䝃 
䝫䞊䝖䛥䜜䛶䛔䜎䛩䚹
䜲䞁䝇䝖䞊䝹䛻䛴䛔䛶 
● ᚑ᮶㏻䜚ISO䝣䜯䜲䝹䛜⏝ព䛥䜜䛶䛔䜎䛩䚹 
○ http://www.centos.org/download/ 
○ ᶆ‽䛷3.9GB䚷᭱኱䛾Everything䛷6.6GB䟿 
○ ᭱ᑠ䛾minimal䛷566MB 
○ 㧗㏿䝛䝑䝖⎔ቃ䛜䛒䜜䜀䚸Netinstall䛷362MB 
● 䜲䞁䝇䝖䞊䝷䞊䛾anaconda 
○ ᚑ᮶䛿䜲䞁䝇䝖䞊䝹䛾㡰䜢㏣䛳䛶䜸䝥䝅䝵䞁䜢タᐃ䛧䛶䛔 
䛯䛜䚸ண䜑䜸䝥䝅䝵䞁䜢㑅ᢥ䛧䛶䛛䜙䜲䞁䝇䝖䞊䝹ᐇ⾜䛜 
ฟ᮶䜛䜘䛖䛻䛺䛳䛯䚹
䜲䞁䝇䝖䞊䝹䛻䛴䛔䛶 
● 䜽䝷䜴䝗⎔ቃ⏝䛾䜲䝯䞊䝆䜢ணᐃ䛧䛶䛔䜎䛩䚹 
○ AWS➼䛾䝟䝤䝸䝑䜽䜽䝷䜴䝗 
○ OpenStack➼䛾䝥䝷䜲䝧䞊䝖䜽䝷䜴䝗 
○ Docker 
● 䜽䝷䜴䝗฼⏝⪅䜢᝿ᐃ䛧䛶䚸Vagrant䛾BOX䝣䜯 
䜲䝹䛻䛶௒ᅇ䛿Ꮫ⩦䛧䛶⾜䛝䜎䛩䚹
᳨ド⎔ቃ 
● VirtualBox 4.3.16(2014/09/11᫬Ⅼ) 
○ https://www.virtualbox.org/wiki/Downloads 
○ CPU䛾௬᝿䝬䝅䞁ᨭ᥼ᶵ⬟䛜ᚲせ(BIOSタᐃ) 
○ Windows䛾ሙྜ䚸䝅䝇䝔䝮䛾PATHタᐃ䛜ᚲせ 
■ 4.2⣔䚷C:Program FilesOracle VM VirtualBox 
■ 4.3⣔䚷C:Program FilesOracleVirtualBox
᳨ド⎔ቃ 
● Vagrant 1.6.5(2014/09/05᫬Ⅼ) 
○ http://www.vagrantup.com/downloads.html 
○ Windows䛾ሙྜ䚸䝅䝇䝔䝮䛾PATHタᐃ䛜ᚲせ 
■ C:HashiCorpVagrantbin 
■ C:HashiCorpVagrantembeddedmingwbin 
○ 䝁䝬䞁䝗䝥䝻䞁䝥䝖䛾௦䜟䜚䛻mingw32䛜౑⏝䛷䛝䜛䚹 
■ C:HashiCorpVagrantembeddedmingwmingw32env.cmd 
● BOX䝣䜯䜲䝹 CentOS 7 
○ https://dl.dropboxusercontent.com/s/w3lbekm7eunrskm/centos-7.0-x86_64.box 
○ CentOS7.0 x86_64 minimal + Puppet + VirtualBoxGuestAddtions 4.3.14
᳨ド⎔ቃ 
● Vagrantfile䜢⦅㞟䛧䛶IP䜰䝗䝺䝇䜢๭䜚ᙜ䛶䛯 
䝜䞊䝗䛷㉳ື䛥䛫䜎䛩䚹 
● Vagrantධ㛛䛾㈨ᩱ䜢ཧ↷䛧䛶ୗ䛥䛔䚹 
○ http://www.slideshare.net/ShinichiroOhhara/solavagrantver2
᳨ド⎔ቃ 
Virtual Box ⎔ቃ 
䜽䝷䜲䜰䞁䝖ഃ 
Ubuntu 14.04 
䝩䝇䝖PC 
䝹䞊䝍䞊 
192.168.33.1 
䝃䞊䝞䞊ഃ 
CentOS7 
192.168.33.70
systemd 
● 䝃䞊䝡䝇⟶⌮䛜systemd䜈ኚ᭦䛻䛺䜚䜎䛧䛯䚹 
○ 䝅䝇䝔䝮䛾㉳ື᫬䚸䝅䝱䝑䝖䝎䜴䞁᫬䛺䛹䚸䝃䞊䝡䝇䝥䝻 
䝉䝇䛾⟶⌮䝅䝇䝔䝮䛜᪂䛧䛟䛺䜚䜎䛧䛯䚹 
● ᚑ᮶䛿UNIX⏤᮶䛾init䛻䛶⟶⌮ 
○ UNIX䛾init䛻䛿䚸SystemV⣔䛸BSD⣔䛜䛒䜛 
○ RHEL5(CentOS5)䜎䛷䛿SysVinit 
○ /etc/inittab䛻タᐃ䛥䜜䛯䝷䞁䝺䝧䝹䛷⟶⌮ 
○ RHEL6(CentOS6)䛛䜙ubuntu䛸ྠ䛨Upstart 
○ /etc/init/௨ୗ䛾タᐃ䝣䜯䜲䝹䛷⟶⌮ 
○ Upstart䛿SysVinit஫᥮ 
○ ஫᥮ᛶ䛾䛒䜛䝅䜵䝹䝇䜽䝸䝥䝖䛷ືస䜢タᐃ
systemd 
● init䜘䜚ኚ䜟䛳䛯䛣䛸 
○ Upstart䜘䜚୪ิᗘ䛾㧗䛔㧗㏿䛺㉳ື䛸⤊஢ 
○ 䝅䜵䝹䝇䜽䝸䝥䝖䛷䛿䛺䛟タᐃ䝣䜯䜲䝹䛻䜘䜛⟶⌮ 
○ 䝃䞊䝡䝇䝥䝻䝉䝇㉳ື䛜ᵝ䚻䛺᪉ἲ䛷ᰂ㌾䛻ฟ᮶䜛 
○ cgroups䛻䜘䜛䝃䞊䝡䝇䝥䝻䝉䝇䛾䝸䝋䞊䝇⟶⌮ 
● Unit 
○ 䝃䞊䝡䝇䝥䝻䝉䝇䛾タᐃ䝣䜯䜲䝹 
○ systemd䛜Unit䛾タᐃ䛷ฎ⌮䛩䜛䚹 
○ ௚䛾Unit䛸㐃ᦠ䠄౫Ꮡ䛸㉳ື㡰䠅䛧䛶ฎ⌮䛜ฟ᮶䜛䚹 
○ ᣑᙇᏊ䛻䜘䛳䛶ᵝ䚻䛺Unit䛾✀㢮䛜䛒䜛䚹 
○ タ⨨ሙᡤ䛿䚸/etc/systemd/system 
○ 䜲䞁䝇䝖䞊䝹ึᮇタᐃ䛿䚸/usr/lib/systemd/system
systemd 
● 䝁䝬䞁䝗 
○ systemctl 䜸䝥䝅䝵䞁 Unitྡ 
○ ᚑ᮶䛸ྠ䛨service䜒౑⏝䛷䛝䜎䛩䚹 
● 䝃䞊䝡䝇䝥䝻䝉䝇䛾㉳ື䛸೵Ṇ 
○ Unit䛾ᣑᙇᏊ䛿䚸䛂.service䛃 
○ sytemctl [start/stop/restart] Unitྡ 
○ reload䜸䝥䝅䝵䞁䛿Unit䛻ᐃ⩏䛥䜜䛶䛔䜛ሙྜ䛾䜏 
● Unitタᐃ䛾ኚ᭦ 
○ Unitタᐃ䜢ኚ᭦䛧䛯᫬䛿䚸systemd䜈཯ᫎ䛥䛫䜎䛩䚹 
○ systemctl daemon-reload 
● 䝥䝻䝉䝇䛾≧ែ☜ㄆ 
○ systemctl status Unitྡ
systemd 
● ⮬ື㉳ື䛾タᐃ 
○ systemctl [enable/disable] Unitྡ 
○ Unit䛾㐃ᦠ䠄౫Ꮡ䠅タᐃ䛜ኚ᭦䛥䜜䜎䛩䚹 
○ Unitタᐃ䝣䜯䜲䝹䛷ᣦᐃ䛧䛯䛂WantedBy=䛃䝕䜱䝺䜽䝖䝸 
䜈䛾䝅䞁䝪䝸䝑䜽䝸䞁䜽 
● Wants 
○ 㐃ᦠ䠄౫Ꮡ䠅䛩䜛Unit䜢タᐃ䛧䜎䛩䚹 
○ Unitタᐃ䝣䜯䜲䝹䛾䛂Wants=䛃 
○ 䝕䜱䝺䜽䝖䝸䛂Unitྡ.wants䛃䜈䝅䞁䝪䝸䝑䜽䝸䞁䜽䜢సᡂ 
● Requires 
○ Wants䛿Unit㛫䛾ྠ᫬㉳ື䛜ኻᩋ䛧䛶䜒෌ᐇ⾜䛧䜎䛩䚹 
○ Requires䛿Unit㛫䛾ྠ᫬㉳ື䛜ኻᩋ䛧䛯䜙⤊஢䛧䜎 
䛩䚹
systemd 
● ⮬ື㉳ື䛾☜ㄆ 
○ systemctl list-unit-files --type=service 
○ enabled䚷→䚷䛂Wants=䛃グ㍕䛒䜚䚸᭷ຠ 
○ disabled䚷→䚷䛂Wants=䛃グ㍕䛒䜚䚸↓ຠ 
○ static䚷→䚷䛂Wants=䛃グ㍕↓䛧 
● ⌧ᅾ䛾Unit≧ែ䛾☜ㄆ 
○ systemctl list-units --type=service 
○ list-units䜸䝥䝅䝵䞁䜢┬␎ฟ᮶䜛䚹 
● Unit䛾㐃ᦠ㛵ಀ䛾☜ㄆ 
○ systemctl list-dependencies 
○ 䝒䝸䞊⾲♧䛷㐃ᦠ䠄౫Ꮡ䛸㉳ື㡰䠅㛵ಀ䜢⾲♧䛩䜛䚹
systemd 
● target 
○ 」ᩘ䛾Unit䜢䜎䛸䜑䛶䚸䜾䝹䞊䝥໬䛷䛝䜛䚹 
○ Unit䛾ᣑᙇᏊ䛿䚸䛂.target䛃 
○ 㛵ಀ䛩䜛」ᩘ䛾Unit䛾㐃ᦠ䠄౫Ꮡ䛸㉳ື㡰䠅䜢⟶⌮䚹 
○ target⮬య䛿ᐇ⾜䛧䛺䛔䚹 
○ ᚑ᮶䛾䝷䞁䝺䝧䝹䛜↓䛟䛺䜚䚸Unit䛾target䛻ኚ䜟䜚䜎䛧 
䛯䚹 
○ ᚑ᮶䛾䝷䞁䝺䝧䝹0䛛䜙6䛸㐪䛔䚸⮬⏤䛻タᐃฟ᮶䜛䚹 
● 䝅䝇䝔䝮䛾㉳ື≧ែ䛾ኚ᭦᪉ἲ 
○ /etc/systemd/system/default.target 
○ 䝅䞁䝪䝸䝑䜽䝸䞁䜽ඛ䜢ኚ᭦䛩䜛䛣䛸䛷䚸䝷䞁䝺䝧䝹┦ᙜ 
䜢ᐇ⌧䛧䛶䛔䜎䛩䚹
systemd 
● ᚑ᮶䛾䝷䞁䝺䝧䝹䛸䛾ᑐẚ 
○ runlevel0䛛䜙runlevel6䛾䝅䞁䝪䝸䝑䜽䝸䞁䜽䜒䛒䜛䚹 
ᚑ᮶䛾䝷䞁䝺䝧䝹 target䝣䜯䜲䝹ྡ ≧ែෆᐜ 
runlevel 䠌 poweroff.target ೵Ṇ 
runlevel 1 rescue.target 䝅䞁䜾䝹䝴䞊䝄䞊䝰䞊䝗 
runlevel 2 multi-user.target 䝬䝹䝏䝴䞊䝄䞊䝰䞊䝗 
runlevel 3 multi-user.target 䝬䝹䝏䝴䞊䝄䞊䝰䞊䝗 
runlevel 4 multi-user.target 䝬䝹䝏䝴䞊䝄䞊䝰䞊䝗 
runlevel 5 graphical.target GUI䝬䝹䝏䝴䞊䝄䞊䝰䞊䝗 
runlevel 6 reboot.target ෌㉳ື
systemd 
● 䛭䛾௚䛾Unit 
○ 䛂service䛃䛂target䛃䛾௚䛻䜒Unit䛾✀㢮䛜䛒䜚䜎䛩䚹 
● mount, swap 
○ /etc/fstab䛛䜙⮬ືసᡂ䛥䜜䜎䛩䚹 
● device 
○ 䝕䝞䜲䝇䛜ㄆ㆑䛩䜛䛸⮬ືసᡂ䛥䜜䜎䛩䚹 
● path 
○ 䝟䝇䜢┘ど䛧䛶䚸䝣䜯䜲䝹䛻ᛂ䛨䛶䝃䞊䝡䝇䜢㉳ື䚹 
● socket 
○ 䝋䜿䝑䝖䜢┘ど䛧䛶䚸᥋⥆䛻ᛂ䛨䛶䝃䞊䝡䝇䜢㉳ື䚹
NetworkManager 
● 䝛䝑䝖䝽䞊䜽䝕䝞䜲䝇タᐃ 
○ /etc/sysconfig/network-scipts/䛻䛒䜛タᐃ䝣䜯䜲䝹䜢┤ 
᥋⦅㞟䛩䜛䛾䛷䛿䛺䛟䚸NetworkManager䜢౑⏝䛩䜛䚹 
○ ᚑ᮶䛾タᐃ䝣䜯䜲䝹䜒฼⏝䛷䛝䜛䚹 
○ Ethernet䜲䞁䝍䞊䝣䜵䞊䝇䛿ᶆ‽䛷䛿↓ຠ䛻䛺䛳䛶䛔 
䜛䚹 
● NetworkManager䝣䝻䞁䝖䜶䞁䝗 
○ GUI䛾GNOME⎔ቃ䛷᧯స䛧䜎䛩䚹 
● nmtui 
○ 䝔䜻䝇䝖⏬㠃䛷ᑐヰⓗ䛻䝛䝑䝖䝽䞊䜽タᐃ䛧䜎䛩䚹
NetworkManager 
● nmcli 
○ 䝁䝬䞁䝗䝷䜲䞁䛷䝛䝑䝖䝽䞊䜽タᐃ䛧䜎䛩䚹 
○ 䝃䞊䝞䞊⟶⌮⪅ྥ䛡䛻䚸䛣䛣䛷䛿nmcli䜢Ꮫ⩦䛧䜎䛩䚹 
● 䝩䝇䝖ྡ䛾ኚ᭦ 
○ nmcli general hostname 䝩䝇䝖ྡ 
○ bmcli g ho 䝩䝇䝖ྡ 䛸┬␎䛷䛝䜛䚹 
○ /etc/hostname䝣䜯䜲䝹䛻タᐃ䛥䜜䜛䚹
NetworkManager 
● nmcli device 
○ ≀⌮䝕䝞䜲䝇䛾⟶⌮ 
● 䝕䝞䜲䝇䛾୍ぴ 
○ nmcli device 
○ nmcli d 䛸┬␎ฟ᮶䜛䚹 
● 䝕䝞䜲䝇䛾ヲ⣽ 
○ nmcli device show 䝕䝞䜲䝇ྡ 
○ nmcli d s 䛸┬␎ฟ᮶䜛䚹
NetworkManager 
● nmcli connection 
○ ᥋⥆タᐃ䛾⟶⌮ 
● ᥋⥆≧ἣ䛾୍ぴ 
○ nmcli connection 
○ nmcli c 䛸┬␎䛷䛝䜛䚹 
○ nmcli --fields 㡯┠ connection 䛷᳨⣴⾲♧䜒ฟ᮶䜛䚹 
● ᥋⥆䛾ヲ⣽ 
○ nmcli connection show ྡ๓䜒䛧䛟䛿UUID 
○ nmcli c s ྡ๓䜒䛧䛟䛿UUID䚷䛸┬␎䛷䛝䜛䚹 
○ ྡ๓䛻䝇䝨䞊䝇䛜䛒䜛䛸䛝䛿䚸䛂”䛃䝎䝤䝹䜽䜷䞊䝔䞊䝅䝵 
䞁䛷ᅖ䜣䛷ᣦᐃ䛩䜛䚹 
○ nmcli c s “Wired connection 1”
NetworkManager 
● ᥋⥆䛾᭷ຠ໬ 
○ nmcli connection up ྡ๓䜒䛧䛟䛿UUID 
● ᥋⥆䛾↓ຠ໬ 
○ nmcli connection down ྡ๓䜒䛧䛟䛿UUID 
● ᥋⥆䛾ືస☜ㄆ 
○ nmcli c s ྡ๓䜒䛧䛟䛿UUID 䛷IP䜰䝗䝺䝇䜢☜ㄆ 
○ ping 䛷␯㏻䜢☜ㄆ 
○ nmcli c d ྡ๓䜒䛧䛟䛿UUID 䛷↓ຠ໬ 
○ ping 䛷␯㏻ฟ᮶䛺䛔䛾䜢☜ㄆ 
○ nmcli c u ྡ๓䜒䛧䛟䛿UUID 䛷᭷ຠ໬ 
○ ping 䛷␯㏻䜢☜ㄆ
NetworkManager 
● タᐃ䛾ኚ᭦ 
○ nmcli connection modify ྡ๓ 㡯┠ タᐃ್ 
○ nmcli c m 䛸┬␎䛷䛝䜛䚹 
● IP䜰䝗䝺䝇䛸䝀䞊䝖䜴䜵䜲䛾ኚ᭦ 
○ DHCP䜢ᡭືタᐃ䜈ኚ᭦䛧䜎䛩䚹 
○ nmcli c m ྡ๓ ipv4.method manual 
○ nmcli c m ྡ๓ ipv4.addresses "IP䜰䝗䝺䝇/䝛䝑䝖䝬䝇 
䜽 䝀䞊䝖䜴䜵䜲" 
○ タᐃኚ᭦䛧䛯䛰䛡䛷䛿䚸タᐃ್䛿᭷ຠ䛻䛺䜙䛺䛔䚹 
○ ᥋⥆䜢down/up䛧䛯ᚋ䛷タᐃ್䛜᭷ຠ䛻䛺䜛䚹
NetworkManager 
● DNS䛾ኚ᭦ 
○ nmcli c m ྡ๓ ipv4.dns "DNS䝃䞊䝞䞊䛾IP䜰䝗䝺䝇" 
● タᐃ್䛾㏣ຍ䛸๐㝖 
○ ᪤Ꮡ䛾್䛻㏣ຍ䛩䜛ሙྜ䛿䚸㡯┠ྡ䛾๓䛻䛂䠇䛃䜢௜䛡 
䜛䚹 
○ ᪤Ꮡ䛾್䛛䜙๐㝖䛩䜛ሙྜ䛿䚸㡯┠ྡ䛾๓䛻䛂䞊䛃䜢௜ 
䛡䜛䚹 
○ nmcli c m ྡ๓ +㡯┠ྡ ್ 
○ nmcli c m ྡ๓ -㡯┠ྡ ್ 
● DHCP䛾タᐃ 
○ nmcli c m ྡ๓ ipv4.method auto
iproute2 
● 䝛䝑䝖䝽䞊䜽タᐃ䝁䝬䞁䝗䛾ኚ᭦ 
○ 䝕䝞䜲䝇ྡ䛜䛂eth␒ྕ䛃䛛䜙䛂enྡ⛠䛃䜈ኚ᭦䛻䛺䜚䜎䛧 
䛯䚹 
○ ᚑ᮶䛾ifconfig,route,arp,netstat䝁䝬䞁䝗䛿㠀᥎ዡ䚹 
○ ᶆ‽䛷䛿౑⏝䛷䛝䜎䛫䜣䚹 
○ ู㏵䚸net-tools䝟䝑䜿䞊䝆䜢䜲䞁䝇䝖䞊䝹䛩䜜䜀౑⏝ฟ 
᮶䜎䛩䚹 
○ yum install net-tools 
○ ᪂䛧䛔iproute2䝟䝑䜿䞊䝆䛾䝁䝬䞁䝗䜢᥎ዡ䛧䜎䛩䚹 
○ ྂ䛔䝁䝬䞁䝗䛿ᛀ䜜䛶᪂䛧䛔䝁䝬䞁䝗䜢Ꮫ⩦䛧䜎䛧䜗䛖䚹
iproute2 
● ip addr show 
○ ipconfig䛻┦ᙜ䛩䜛䝁䝬䞁䝗䚹 
○ 䝕䝞䜲䝇䛾䜰䝗䝺䝇䜢⾲♧䛩䜛䚹 
○ ฎ⌮䝟䜿䝑䝖䛾⤫ィ䛿⾲♧䛥䜜䛺䛔䚹 
● ip -s link 
○ ipconfig䛻┦ᙜ䛩䜛䝁䝬䞁䝗䚹 
○ ᥋⥆䛾ฎ⌮䝟䜿䝑䝖䛾⤫ィ䜢⾲♧䛩䜛䚹 
● ip route 
○ route䛻┦ᙜ䛩䜛䝁䝬䞁䝗䚹 
○ 䝹䞊䝔䜱䞁䜾䝔䞊䝤䝹䜢⾲♧䛩䜛䚹
iproute2 
● ip neigh 
○ arp䛻┦ᙜ䛩䜛䝁䝬䞁䝗䚹 
○ 䝕䝞䜲䝇䛾Mac䜰䝗䝺䝇䜢⾲♧䛩䜛䚹 
● ip䝁䝬䞁䝗 
○ ྛ䝛䝑䝖䝽䞊䜽タᐃ䜢ኚ᭦䛩䜛䛣䛸䛜ฟ᮶䜎䛩䚹 
○ 䝕䝞䜲䝇䜢down/up䛩䜛஦↓䛟䚸タᐃ䛿༶཯ᫎ䛧䜎䛩䚹 
○ タᐃ್䛿ಖᏑ䛥䜜䜎䛫䜣䚹 
● ss 
○ netstat䛻┦ᙜ䛩䜛䝁䝬䞁䝗䚹 
○ 䝃䞊䝡䝇䛾౑⏝≧ἣ䜢⾲♧䛩䜛䚹

More Related Content

What's hot

Git inter-snapshot public
Git  inter-snapshot publicGit  inter-snapshot public
Git inter-snapshot publicSeongJae Park
 
Gitosis on Mac OS X Server
Gitosis on Mac OS X ServerGitosis on Mac OS X Server
Gitosis on Mac OS X ServerYasuhiro Asaka
 
Clean Manifests with Puppet::Tidy
Clean Manifests with Puppet::TidyClean Manifests with Puppet::Tidy
Clean Manifests with Puppet::TidyPuppet
 
DO YOU WANT TO USE A VCS
DO YOU WANT TO USE A VCSDO YOU WANT TO USE A VCS
DO YOU WANT TO USE A VCSSeongJae Park
 
GitGot: The Swiss Army Chainsaw of Git Repo Management
GitGot: The Swiss Army Chainsaw of Git Repo ManagementGitGot: The Swiss Army Chainsaw of Git Repo Management
GitGot: The Swiss Army Chainsaw of Git Repo ManagementJohn Anderson
 
(120513) #fitalk an introduction to linux memory forensics
(120513) #fitalk   an introduction to linux memory forensics(120513) #fitalk   an introduction to linux memory forensics
(120513) #fitalk an introduction to linux memory forensicsINSIGHT FORENSIC
 
slides.pdf
slides.pdfslides.pdf
slides.pdfvidsvagi
 
OSS AWS 핸즈온 강의
OSS AWS 핸즈온 강의OSS AWS 핸즈온 강의
OSS AWS 핸즈온 강의Juhong Jung
 
Update Lexia 3 DiagBox 7.61
Update Lexia 3 DiagBox 7.61 Update Lexia 3 DiagBox 7.61
Update Lexia 3 DiagBox 7.61 buyobdii
 
Plagger the duct tape of internet
Plagger the duct tape of internetPlagger the duct tape of internet
Plagger the duct tape of internetTatsuhiko Miyagawa
 
Container: is it safe enough to run you application?
Container: is it safe enough to run you application?Container: is it safe enough to run you application?
Container: is it safe enough to run you application?Aleksey Zalesov
 
[로켓 자바] Part 1 성능 튜닝 마인드 확립
[로켓 자바] Part 1 성능 튜닝 마인드 확립[로켓 자바] Part 1 성능 튜닝 마인드 확립
[로켓 자바] Part 1 성능 튜닝 마인드 확립Covenant Ko
 
Intro to pl/PHP Oscon2007
Intro to pl/PHP Oscon2007Intro to pl/PHP Oscon2007
Intro to pl/PHP Oscon2007Robert Treat
 
Linux & Open Source - Alternative Software
Linux & Open Source - Alternative SoftwareLinux & Open Source - Alternative Software
Linux & Open Source - Alternative SoftwareSebastiano Merlino (eTr)
 
Creating "Secure" PHP applications, Part 2, Server Hardening
Creating "Secure" PHP applications, Part 2, Server HardeningCreating "Secure" PHP applications, Part 2, Server Hardening
Creating "Secure" PHP applications, Part 2, Server Hardeningarchwisp
 
Install odoo v8 the easiest way on ubuntu debian
Install odoo v8 the easiest way on ubuntu debianInstall odoo v8 the easiest way on ubuntu debian
Install odoo v8 the easiest way on ubuntu debianFrancisco Servera
 

What's hot (20)

Starting python
Starting pythonStarting python
Starting python
 
Git inter-snapshot public
Git  inter-snapshot publicGit  inter-snapshot public
Git inter-snapshot public
 
Git cli
Git cliGit cli
Git cli
 
Gitosis on Mac OS X Server
Gitosis on Mac OS X ServerGitosis on Mac OS X Server
Gitosis on Mac OS X Server
 
Clean Manifests with Puppet::Tidy
Clean Manifests with Puppet::TidyClean Manifests with Puppet::Tidy
Clean Manifests with Puppet::Tidy
 
DO YOU WANT TO USE A VCS
DO YOU WANT TO USE A VCSDO YOU WANT TO USE A VCS
DO YOU WANT TO USE A VCS
 
GitGot: The Swiss Army Chainsaw of Git Repo Management
GitGot: The Swiss Army Chainsaw of Git Repo ManagementGitGot: The Swiss Army Chainsaw of Git Repo Management
GitGot: The Swiss Army Chainsaw of Git Repo Management
 
(120513) #fitalk an introduction to linux memory forensics
(120513) #fitalk   an introduction to linux memory forensics(120513) #fitalk   an introduction to linux memory forensics
(120513) #fitalk an introduction to linux memory forensics
 
slides.pdf
slides.pdfslides.pdf
slides.pdf
 
OSS AWS 핸즈온 강의
OSS AWS 핸즈온 강의OSS AWS 핸즈온 강의
OSS AWS 핸즈온 강의
 
Update Lexia 3 DiagBox 7.61
Update Lexia 3 DiagBox 7.61 Update Lexia 3 DiagBox 7.61
Update Lexia 3 DiagBox 7.61
 
Plagger the duct tape of internet
Plagger the duct tape of internetPlagger the duct tape of internet
Plagger the duct tape of internet
 
Container: is it safe enough to run you application?
Container: is it safe enough to run you application?Container: is it safe enough to run you application?
Container: is it safe enough to run you application?
 
Filelist
FilelistFilelist
Filelist
 
[로켓 자바] Part 1 성능 튜닝 마인드 확립
[로켓 자바] Part 1 성능 튜닝 마인드 확립[로켓 자바] Part 1 성능 튜닝 마인드 확립
[로켓 자바] Part 1 성능 튜닝 마인드 확립
 
Intro to pl/PHP Oscon2007
Intro to pl/PHP Oscon2007Intro to pl/PHP Oscon2007
Intro to pl/PHP Oscon2007
 
Git basics
Git basicsGit basics
Git basics
 
Linux & Open Source - Alternative Software
Linux & Open Source - Alternative SoftwareLinux & Open Source - Alternative Software
Linux & Open Source - Alternative Software
 
Creating "Secure" PHP applications, Part 2, Server Hardening
Creating "Secure" PHP applications, Part 2, Server HardeningCreating "Secure" PHP applications, Part 2, Server Hardening
Creating "Secure" PHP applications, Part 2, Server Hardening
 
Install odoo v8 the easiest way on ubuntu debian
Install odoo v8 the easiest way on ubuntu debianInstall odoo v8 the easiest way on ubuntu debian
Install odoo v8 the easiest way on ubuntu debian
 

Similar to CentOS 7 入門

IaaS業界激変の背景
IaaS業界激変の背景IaaS業界激変の背景
IaaS業界激変の背景知礼 八子
 
CEDEC2014 Live Coding in C++
CEDEC2014 Live Coding in C++CEDEC2014 Live Coding in C++
CEDEC2014 Live Coding in C++Seiya Ishibashi
 
Shizuoka.py #4 pythonで設定ファイルを使う 質疑と資料について追記版
Shizuoka.py #4 pythonで設定ファイルを使う 質疑と資料について追記版Shizuoka.py #4 pythonで設定ファイルを使う 質疑と資料について追記版
Shizuoka.py #4 pythonで設定ファイルを使う 質疑と資料について追記版hiroshi sano
 
Grnxx 2014-11-29
Grnxx 2014-11-29Grnxx 2014-11-29
Grnxx 2014-11-29s5yata
 
Qemu上でlagopusを動かした話
Qemu上でlagopusを動かした話Qemu上でlagopusを動かした話
Qemu上でlagopusを動かした話Masaru Oki
 
[Android]Fragmentとのつきあい方を考える
[Android]Fragmentとのつきあい方を考える[Android]Fragmentとのつきあい方を考える
[Android]Fragmentとのつきあい方を考えるichigotake .
 
Micro Python で組み込み Python
Micro Python で組み込み PythonMicro Python で組み込み Python
Micro Python で組み込み PythonHirotaka Kawata
 
松本Linux勉強会 SSH 暗号化と認証のプロトコル
松本Linux勉強会 SSH 暗号化と認証のプロトコル松本Linux勉強会 SSH 暗号化と認証のプロトコル
松本Linux勉強会 SSH 暗号化と認証のプロトコルShiojiri Ohhara
 
Cordovaで業務アプリを作る 〜その事例とノウハウ〜
Cordovaで業務アプリを作る 〜その事例とノウハウ〜Cordovaで業務アプリを作る 〜その事例とノウハウ〜
Cordovaで業務アプリを作る 〜その事例とノウハウ〜Kenichi Inoue
 
2014 09-23 Mechanism of Gossip protocol
2014 09-23 Mechanism of Gossip protocol2014 09-23 Mechanism of Gossip protocol
2014 09-23 Mechanism of Gossip protocolSugawara Genki
 
ごみカレンダー
ごみカレンダーごみカレンダー
ごみカレンダーrarere
 
Solving the Package Problem
Solving the Package ProblemSolving the Package Problem
Solving the Package ProblemJoe Brockmeier
 
東南アジアでエンジニア
東南アジアでエンジニア東南アジアでエンジニア
東南アジアでエンジニアHirakawa Akira
 
第25回高専プロコン競技部門(府大高専)
第25回高専プロコン競技部門(府大高専)第25回高専プロコン競技部門(府大高専)
第25回高専プロコン競技部門(府大高専)opuctplab
 
Android Wear のムダ知識
Android Wear のムダ知識Android Wear のムダ知識
Android Wear のムダ知識Satoshi Noda
 
Logging and ranting / Vytis Valentinavičius (Lamoda)
Logging and ranting / Vytis Valentinavičius (Lamoda)Logging and ranting / Vytis Valentinavičius (Lamoda)
Logging and ranting / Vytis Valentinavičius (Lamoda)Ontico
 
Drupal Deployment and Essential Development Tools - 2nd Edition
Drupal Deployment and Essential Development Tools - 2nd EditionDrupal Deployment and Essential Development Tools - 2nd Edition
Drupal Deployment and Essential Development Tools - 2nd EditionGerald Villorente
 
SUSE Open Forum講演 - OpenStack Summit 2014 Paris 報告
SUSE Open Forum講演 - OpenStack Summit 2014 Paris 報告SUSE Open Forum講演 - OpenStack Summit 2014 Paris 報告
SUSE Open Forum講演 - OpenStack Summit 2014 Paris 報告VirtualTech Japan Inc.
 

Similar to CentOS 7 入門 (20)

IaaS業界激変の背景
IaaS業界激変の背景IaaS業界激変の背景
IaaS業界激変の背景
 
CEDEC2014 Live Coding in C++
CEDEC2014 Live Coding in C++CEDEC2014 Live Coding in C++
CEDEC2014 Live Coding in C++
 
Shizuoka.py #4 pythonで設定ファイルを使う 質疑と資料について追記版
Shizuoka.py #4 pythonで設定ファイルを使う 質疑と資料について追記版Shizuoka.py #4 pythonで設定ファイルを使う 質疑と資料について追記版
Shizuoka.py #4 pythonで設定ファイルを使う 質疑と資料について追記版
 
Grnxx 2014-11-29
Grnxx 2014-11-29Grnxx 2014-11-29
Grnxx 2014-11-29
 
Qemu上でlagopusを動かした話
Qemu上でlagopusを動かした話Qemu上でlagopusを動かした話
Qemu上でlagopusを動かした話
 
[Android]Fragmentとのつきあい方を考える
[Android]Fragmentとのつきあい方を考える[Android]Fragmentとのつきあい方を考える
[Android]Fragmentとのつきあい方を考える
 
Arduino
ArduinoArduino
Arduino
 
Micro Python で組み込み Python
Micro Python で組み込み PythonMicro Python で組み込み Python
Micro Python で組み込み Python
 
松本Linux勉強会 SSH 暗号化と認証のプロトコル
松本Linux勉強会 SSH 暗号化と認証のプロトコル松本Linux勉強会 SSH 暗号化と認証のプロトコル
松本Linux勉強会 SSH 暗号化と認証のプロトコル
 
Cordovaで業務アプリを作る 〜その事例とノウハウ〜
Cordovaで業務アプリを作る 〜その事例とノウハウ〜Cordovaで業務アプリを作る 〜その事例とノウハウ〜
Cordovaで業務アプリを作る 〜その事例とノウハウ〜
 
2014 09-23 Mechanism of Gossip protocol
2014 09-23 Mechanism of Gossip protocol2014 09-23 Mechanism of Gossip protocol
2014 09-23 Mechanism of Gossip protocol
 
ごみカレンダー
ごみカレンダーごみカレンダー
ごみカレンダー
 
Solving the Package Problem
Solving the Package ProblemSolving the Package Problem
Solving the Package Problem
 
東南アジアでエンジニア
東南アジアでエンジニア東南アジアでエンジニア
東南アジアでエンジニア
 
第25回高専プロコン競技部門(府大高専)
第25回高専プロコン競技部門(府大高専)第25回高専プロコン競技部門(府大高専)
第25回高専プロコン競技部門(府大高専)
 
Android Wear のムダ知識
Android Wear のムダ知識Android Wear のムダ知識
Android Wear のムダ知識
 
Logging and ranting / Vytis Valentinavičius (Lamoda)
Logging and ranting / Vytis Valentinavičius (Lamoda)Logging and ranting / Vytis Valentinavičius (Lamoda)
Logging and ranting / Vytis Valentinavičius (Lamoda)
 
Docker勉強会
Docker勉強会Docker勉強会
Docker勉強会
 
Drupal Deployment and Essential Development Tools - 2nd Edition
Drupal Deployment and Essential Development Tools - 2nd EditionDrupal Deployment and Essential Development Tools - 2nd Edition
Drupal Deployment and Essential Development Tools - 2nd Edition
 
SUSE Open Forum講演 - OpenStack Summit 2014 Paris 報告
SUSE Open Forum講演 - OpenStack Summit 2014 Paris 報告SUSE Open Forum講演 - OpenStack Summit 2014 Paris 報告
SUSE Open Forum講演 - OpenStack Summit 2014 Paris 報告
 

More from Shiojiri Ohhara

ランサムウェアのおはなし
ランサムウェアのおはなしランサムウェアのおはなし
ランサムウェアのおはなしShiojiri Ohhara
 
フィッシングとドメイン名・DNS
フィッシングとドメイン名・DNSフィッシングとドメイン名・DNS
フィッシングとドメイン名・DNSShiojiri Ohhara
 
フィッシングメール
フィッシングメールフィッシングメール
フィッシングメールShiojiri Ohhara
 
見えないから恐ろしい!標的型サイバー攻撃の脅威
見えないから恐ろしい!標的型サイバー攻撃の脅威見えないから恐ろしい!標的型サイバー攻撃の脅威
見えないから恐ろしい!標的型サイバー攻撃の脅威Shiojiri Ohhara
 
転ばぬ先の杖 Windows Update
転ばぬ先の杖 Windows Update転ばぬ先の杖 Windows Update
転ばぬ先の杖 Windows UpdateShiojiri Ohhara
 
フィッシングメールの紹介と対策
フィッシングメールの紹介と対策フィッシングメールの紹介と対策
フィッシングメールの紹介と対策Shiojiri Ohhara
 
パスワード再入門
パスワード再入門パスワード再入門
パスワード再入門Shiojiri Ohhara
 
夏休みのサイバー自由研究 (1)DockerコンテナでVuls!
夏休みのサイバー自由研究 (1)DockerコンテナでVuls!夏休みのサイバー自由研究 (1)DockerコンテナでVuls!
夏休みのサイバー自由研究 (1)DockerコンテナでVuls!Shiojiri Ohhara
 
オープンソースで始めるLinuxサーバー脆弱性診断入門
オープンソースで始めるLinuxサーバー脆弱性診断入門オープンソースで始めるLinuxサーバー脆弱性診断入門
オープンソースで始めるLinuxサーバー脆弱性診断入門Shiojiri Ohhara
 
Docker勉強会2017 最新基礎・応用編
Docker勉強会2017 最新基礎・応用編Docker勉強会2017 最新基礎・応用編
Docker勉強会2017 最新基礎・応用編Shiojiri Ohhara
 
サイバーセキュリティ勉強会2017 in 塩尻
サイバーセキュリティ勉強会2017 in 塩尻サイバーセキュリティ勉強会2017 in 塩尻
サイバーセキュリティ勉強会2017 in 塩尻Shiojiri Ohhara
 
Docker勉強会2017 実践編 スライド
Docker勉強会2017 実践編 スライドDocker勉強会2017 実践編 スライド
Docker勉強会2017 実践編 スライドShiojiri Ohhara
 
Docker 再入門 2016 update
Docker 再入門 2016 updateDocker 再入門 2016 update
Docker 再入門 2016 updateShiojiri Ohhara
 
DNSとサイバー攻撃
DNSとサイバー攻撃DNSとサイバー攻撃
DNSとサイバー攻撃Shiojiri Ohhara
 
Open stack 勉強会 in 塩尻
Open stack 勉強会 in 塩尻Open stack 勉強会 in 塩尻
Open stack 勉強会 in 塩尻Shiojiri Ohhara
 
サイバーセキュリティ勉強会
サイバーセキュリティ勉強会サイバーセキュリティ勉強会
サイバーセキュリティ勉強会Shiojiri Ohhara
 
小型コンピューターで楽しく学ぼう!
小型コンピューターで楽しく学ぼう!小型コンピューターで楽しく学ぼう!
小型コンピューターで楽しく学ぼう!Shiojiri Ohhara
 
Ubuntu LibreOffice Update
Ubuntu LibreOffice UpdateUbuntu LibreOffice Update
Ubuntu LibreOffice UpdateShiojiri Ohhara
 
松本Linux勉強会 vagrant入門
松本Linux勉強会 vagrant入門松本Linux勉強会 vagrant入門
松本Linux勉強会 vagrant入門Shiojiri Ohhara
 

More from Shiojiri Ohhara (20)

ランサムウェアのおはなし
ランサムウェアのおはなしランサムウェアのおはなし
ランサムウェアのおはなし
 
フィッシングとドメイン名・DNS
フィッシングとドメイン名・DNSフィッシングとドメイン名・DNS
フィッシングとドメイン名・DNS
 
フィッシングメール
フィッシングメールフィッシングメール
フィッシングメール
 
見えないから恐ろしい!標的型サイバー攻撃の脅威
見えないから恐ろしい!標的型サイバー攻撃の脅威見えないから恐ろしい!標的型サイバー攻撃の脅威
見えないから恐ろしい!標的型サイバー攻撃の脅威
 
転ばぬ先の杖 Windows Update
転ばぬ先の杖 Windows Update転ばぬ先の杖 Windows Update
転ばぬ先の杖 Windows Update
 
フィッシングメールの紹介と対策
フィッシングメールの紹介と対策フィッシングメールの紹介と対策
フィッシングメールの紹介と対策
 
パスワード再入門
パスワード再入門パスワード再入門
パスワード再入門
 
夏休みのサイバー自由研究 (1)DockerコンテナでVuls!
夏休みのサイバー自由研究 (1)DockerコンテナでVuls!夏休みのサイバー自由研究 (1)DockerコンテナでVuls!
夏休みのサイバー自由研究 (1)DockerコンテナでVuls!
 
オープンソースで始めるLinuxサーバー脆弱性診断入門
オープンソースで始めるLinuxサーバー脆弱性診断入門オープンソースで始めるLinuxサーバー脆弱性診断入門
オープンソースで始めるLinuxサーバー脆弱性診断入門
 
Docker勉強会2017 最新基礎・応用編
Docker勉強会2017 最新基礎・応用編Docker勉強会2017 最新基礎・応用編
Docker勉強会2017 最新基礎・応用編
 
サイバーセキュリティ勉強会2017 in 塩尻
サイバーセキュリティ勉強会2017 in 塩尻サイバーセキュリティ勉強会2017 in 塩尻
サイバーセキュリティ勉強会2017 in 塩尻
 
Docker勉強会2017 実践編 スライド
Docker勉強会2017 実践編 スライドDocker勉強会2017 実践編 スライド
Docker勉強会2017 実践編 スライド
 
Docker 再入門 2016 update
Docker 再入門 2016 updateDocker 再入門 2016 update
Docker 再入門 2016 update
 
DNSとサイバー攻撃
DNSとサイバー攻撃DNSとサイバー攻撃
DNSとサイバー攻撃
 
Open stack 勉強会 in 塩尻
Open stack 勉強会 in 塩尻Open stack 勉強会 in 塩尻
Open stack 勉強会 in 塩尻
 
サイバーセキュリティ勉強会
サイバーセキュリティ勉強会サイバーセキュリティ勉強会
サイバーセキュリティ勉強会
 
小型コンピューターで楽しく学ぼう!
小型コンピューターで楽しく学ぼう!小型コンピューターで楽しく学ぼう!
小型コンピューターで楽しく学ぼう!
 
Ubuntu LibreOffice Update
Ubuntu LibreOffice UpdateUbuntu LibreOffice Update
Ubuntu LibreOffice Update
 
Docker入門
Docker入門Docker入門
Docker入門
 
松本Linux勉強会 vagrant入門
松本Linux勉強会 vagrant入門松本Linux勉強会 vagrant入門
松本Linux勉強会 vagrant入門
 

Recently uploaded

Cloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEECloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEEVICTOR MAESTRE RAMIREZ
 
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfGOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfAlina Yurenko
 
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024StefanoLambiase
 
cpct NetworkING BASICS AND NETWORK TOOL.ppt
cpct NetworkING BASICS AND NETWORK TOOL.pptcpct NetworkING BASICS AND NETWORK TOOL.ppt
cpct NetworkING BASICS AND NETWORK TOOL.pptrcbcrtm
 
Balasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
Balasore Best It Company|| Top 10 IT Company || Balasore Software company OdishaBalasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
Balasore Best It Company|| Top 10 IT Company || Balasore Software company Odishasmiwainfosol
 
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样umasea
 
Software Project Health Check: Best Practices and Techniques for Your Product...
Software Project Health Check: Best Practices and Techniques for Your Product...Software Project Health Check: Best Practices and Techniques for Your Product...
Software Project Health Check: Best Practices and Techniques for Your Product...Velvetech LLC
 
英国UN学位证,北安普顿大学毕业证书1:1制作
英国UN学位证,北安普顿大学毕业证书1:1制作英国UN学位证,北安普顿大学毕业证书1:1制作
英国UN学位证,北安普顿大学毕业证书1:1制作qr0udbr0
 
Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Hr365.us smith
 
Software Coding for software engineering
Software Coding for software engineeringSoftware Coding for software engineering
Software Coding for software engineeringssuserb3a23b
 
Exploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdf
Exploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdfExploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdf
Exploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdfkalichargn70th171
 
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte GermanySuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte GermanyChristoph Pohl
 
React Server Component in Next.js by Hanief Utama
React Server Component in Next.js by Hanief UtamaReact Server Component in Next.js by Hanief Utama
React Server Component in Next.js by Hanief UtamaHanief Utama
 
Intelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmIntelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmSujith Sukumaran
 
MYjobs Presentation Django-based project
MYjobs Presentation Django-based projectMYjobs Presentation Django-based project
MYjobs Presentation Django-based projectAnoyGreter
 
Unveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML DiagramsUnveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML DiagramsAhmed Mohamed
 
PREDICTING RIVER WATER QUALITY ppt presentation
PREDICTING  RIVER  WATER QUALITY  ppt presentationPREDICTING  RIVER  WATER QUALITY  ppt presentation
PREDICTING RIVER WATER QUALITY ppt presentationvaddepallysandeep122
 
Introduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdfIntroduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdfFerryKemperman
 

Recently uploaded (20)

Cloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEECloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEE
 
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfGOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
 
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024
 
Advantages of Odoo ERP 17 for Your Business
Advantages of Odoo ERP 17 for Your BusinessAdvantages of Odoo ERP 17 for Your Business
Advantages of Odoo ERP 17 for Your Business
 
cpct NetworkING BASICS AND NETWORK TOOL.ppt
cpct NetworkING BASICS AND NETWORK TOOL.pptcpct NetworkING BASICS AND NETWORK TOOL.ppt
cpct NetworkING BASICS AND NETWORK TOOL.ppt
 
Balasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
Balasore Best It Company|| Top 10 IT Company || Balasore Software company OdishaBalasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
Balasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
 
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
 
Software Project Health Check: Best Practices and Techniques for Your Product...
Software Project Health Check: Best Practices and Techniques for Your Product...Software Project Health Check: Best Practices and Techniques for Your Product...
Software Project Health Check: Best Practices and Techniques for Your Product...
 
英国UN学位证,北安普顿大学毕业证书1:1制作
英国UN学位证,北安普顿大学毕业证书1:1制作英国UN学位证,北安普顿大学毕业证书1:1制作
英国UN学位证,北安普顿大学毕业证书1:1制作
 
Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)
 
Software Coding for software engineering
Software Coding for software engineeringSoftware Coding for software engineering
Software Coding for software engineering
 
Hot Sexy call girls in Patel Nagar🔝 9953056974 🔝 escort Service
Hot Sexy call girls in Patel Nagar🔝 9953056974 🔝 escort ServiceHot Sexy call girls in Patel Nagar🔝 9953056974 🔝 escort Service
Hot Sexy call girls in Patel Nagar🔝 9953056974 🔝 escort Service
 
Exploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdf
Exploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdfExploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdf
Exploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdf
 
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte GermanySuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
 
React Server Component in Next.js by Hanief Utama
React Server Component in Next.js by Hanief UtamaReact Server Component in Next.js by Hanief Utama
React Server Component in Next.js by Hanief Utama
 
Intelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmIntelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalm
 
MYjobs Presentation Django-based project
MYjobs Presentation Django-based projectMYjobs Presentation Django-based project
MYjobs Presentation Django-based project
 
Unveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML DiagramsUnveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML Diagrams
 
PREDICTING RIVER WATER QUALITY ppt presentation
PREDICTING  RIVER  WATER QUALITY  ppt presentationPREDICTING  RIVER  WATER QUALITY  ppt presentation
PREDICTING RIVER WATER QUALITY ppt presentation
 
Introduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdfIntroduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdf
 

CentOS 7 入門

  • 1. CentOS 7 ධ㛛 ᪂䛧䛟⏕䜎䜜ኚ䜟䛳䛯CentOS
  • 2. ⮬ᕫ⤂௓ ኱ཎ ៅ୍㑻䚷https://twitter.com/ohhara_shiojiri 䠄᭷䠅䝖䝷䝇䝖䝛䝑䝖䝽䞊䜽䝇䚷ሷᑼ䜲䞁䜻䝳䝧䞊䝅䝵䞁䝥䝷䝄䠍䠌䠔ྕᐊ http://shiojiri-osslabo.com/ 䞉㛗㔝┴ሷᑼᕷ䛻άືᣐⅬ䜢⨨䛟䚸ᕷෆ䝥䝻䜾䝷䝬䞊᭷ᚿ䛻䜘䜛ᅋయ 䞉䛂䜸䞊䝥䞁䛺⎔ቃ䛷䜸䞊䝥䞁䛺άື䜢┠ᣦ䛩䛃䜢ྜゝⴥ䛻㞟䛖 䞉CoderDojo Shiojiri 㛤ദ䚷䞉ᑠᏛ⏕㧗Ꮫᖺྥ䛡Rubyᩍᐊ㛤ദ 䞉ITᢏ⾡᭩䜢䝸䝤䝷䜲䝈䛷㈚䛧ฟ䛧䚸䜎䛯ᕷ❧ᅗ᭩㤋䛸༠ຊ
  • 3. 䜰䝆䜵䞁䝎 ● CentOS䛻䛴䛔䛶 ● RHEL 7 䛻䛴䛔䛶 ● LAMP⎔ቃ䛻䛴䛔䛶 ● 䜲䞁䝇䝖䞊䝹䛻䛴䛔䛶 ● ᳨ド⎔ቃ ● systemd ● NetworkManager ● iproute2
  • 4. CentOS䛻䛴䛔䛶 ● Red Hat Enterprise Linux(RHEL)䜽䝻䞊䞁 ௚䛻Ꮫ⾡ྥ䛡䛻Scientific Linux ● RHEL䛛䜙ၟᶆ䜔ၟ⏝䛾䝟䝑䜿䞊䝆䜢㝖እ ● Community ENTerprise Operating System ● Red Hat♫䛾᭷ൾ䝃䝫䞊䝖䜢ᚲせ䛸䛧䛺䛔⏝㏵ ● 2014ᖺ1᭶Red Hat♫䛜ᨭ᥼⾲᫂ ● RHEL䛸㧗䛔஫᥮ᛶ
  • 5. RHEL 7 䛻䛴䛔䛶 ● 2014ᖺ6᭶10᪥䝸䝸䞊䝇 ● 10ᖺ㛫䝃䝫䞊䝖䚷2024ᖺ6᭶30᪥䜎䛷 ● Fedora19䜢䝧䞊䝇 ● 䜹䞊䝛䝹䝞䞊䝆䝵䞁 3.10 ● 64bit䛾䜏 x86_64/ppc64/s390s䝃䝫䞊䝖 ● ext4 → xfs䚷᭱኱500TB䝃䝫䞊䝖 ● GRUB Legacy → GRUB2䚷UEFI䝃䝫䞊䝖
  • 6. LAMP⎔ቃ䛻䛴䛔䛶 ● LAMP⎔ቃ䛸䛧䛶䛾CentOS ○ ᚑ᮶䝅䝇䝔䝮䛸䛾஫᥮ᛶ䛸Ᏻᐃᛶ䜢㔜ど䛧䛶䚸ᶆ‽䝟䝑 䜿䞊䝆䛾䝞䞊䝆䝵䞁䛿ྂ䛔䜎䜎䛷䛧䛯䚹 ○ ྂ䛔䝞䞊䝆䝵䞁䛾䝃䝫䞊䝖䛜⥆䚻䛸⤊஢䛧䛶䛔䜛䚹 ○ ᛶ⬟ྥୖ䚸ᶵ⬟ྥୖ䚸䝉䜻䝳䝸䝔䜱ྥୖ䛜ồ䜑䜙䜜䜛䚹 ○ RHEL7(CentOS7)䛛䜙᪂䛧䛔䝞䞊䝆䝵䞁䜢᥇⏝䟿 ● CentOS6.5䛾LAMP⎔ቃ ○ Apache䚷→䚷2.2.15䚷㛤Ⓨ⤊஢䚷᪂∧⛣⾜䜢᥎ዡ ○ MySQL䚷→䚷5.1.73䚷㛤Ⓨ⤊஢䚷᪂∧⛣⾜䜢᥎ዡ ○ PHP䚷→䚷5.3.3䚷㛤Ⓨ⤊஢䚷᪂∧⛣⾜䜢᥎ዡ ○ Perl䚷→䚷5.10.1 ○ Python䚷→䚷2.6.6
  • 7. LAMP⎔ቃ䛻䛴䛔䛶 ● CentOS7䛾LAMP⎔ቃ ○ Apache䚷→䚷2.4.6䚷᭱᪂ᶵ⬟䛾Ᏻᐃ∧ ○ MySQL䚷→䚷MySQL5.5஫᥮䛾MariaDB 5.5.37 ○ PHP䚷→䚷5.4.16䚷᭱᪂䛾PHP䛿5.6.0 ○ Perl䚷→䚷5.16.3䚷᭱᪂䛾Perl䛿5.20.0 ○ Python䚷→䚷2.7.5䚷᭱᪂䛾Python䛿3.4.1 ○ ྛ䝞䞊䝆䝵䞁䛿2014ᖺ9᭶10᪥᫬Ⅼ䛷䛩䚹 ● CentOS6.5䛷LAMP⎔ቃ䛾᪂䝞䞊䝆䝵䞁ᵓ⠏ 䛿኱ኚ㠃ಽ䛺䛾䛷䚸CentOS7䜢฼⏝䛧䜎䛧䜗 䛖䚹 ● CentOS6.5䛛䜙CentOS7䜈䛾⛣⾜䛜බᘧ䝃 䝫䞊䝖䛥䜜䛶䛔䜎䛩䚹
  • 8. 䜲䞁䝇䝖䞊䝹䛻䛴䛔䛶 ● ᚑ᮶㏻䜚ISO䝣䜯䜲䝹䛜⏝ព䛥䜜䛶䛔䜎䛩䚹 ○ http://www.centos.org/download/ ○ ᶆ‽䛷3.9GB䚷᭱኱䛾Everything䛷6.6GB䟿 ○ ᭱ᑠ䛾minimal䛷566MB ○ 㧗㏿䝛䝑䝖⎔ቃ䛜䛒䜜䜀䚸Netinstall䛷362MB ● 䜲䞁䝇䝖䞊䝷䞊䛾anaconda ○ ᚑ᮶䛿䜲䞁䝇䝖䞊䝹䛾㡰䜢㏣䛳䛶䜸䝥䝅䝵䞁䜢タᐃ䛧䛶䛔 䛯䛜䚸ண䜑䜸䝥䝅䝵䞁䜢㑅ᢥ䛧䛶䛛䜙䜲䞁䝇䝖䞊䝹ᐇ⾜䛜 ฟ᮶䜛䜘䛖䛻䛺䛳䛯䚹
  • 9. 䜲䞁䝇䝖䞊䝹䛻䛴䛔䛶 ● 䜽䝷䜴䝗⎔ቃ⏝䛾䜲䝯䞊䝆䜢ணᐃ䛧䛶䛔䜎䛩䚹 ○ AWS➼䛾䝟䝤䝸䝑䜽䜽䝷䜴䝗 ○ OpenStack➼䛾䝥䝷䜲䝧䞊䝖䜽䝷䜴䝗 ○ Docker ● 䜽䝷䜴䝗฼⏝⪅䜢᝿ᐃ䛧䛶䚸Vagrant䛾BOX䝣䜯 䜲䝹䛻䛶௒ᅇ䛿Ꮫ⩦䛧䛶⾜䛝䜎䛩䚹
  • 10. ᳨ド⎔ቃ ● VirtualBox 4.3.16(2014/09/11᫬Ⅼ) ○ https://www.virtualbox.org/wiki/Downloads ○ CPU䛾௬᝿䝬䝅䞁ᨭ᥼ᶵ⬟䛜ᚲせ(BIOSタᐃ) ○ Windows䛾ሙྜ䚸䝅䝇䝔䝮䛾PATHタᐃ䛜ᚲせ ■ 4.2⣔䚷C:Program FilesOracle VM VirtualBox ■ 4.3⣔䚷C:Program FilesOracleVirtualBox
  • 11. ᳨ド⎔ቃ ● Vagrant 1.6.5(2014/09/05᫬Ⅼ) ○ http://www.vagrantup.com/downloads.html ○ Windows䛾ሙྜ䚸䝅䝇䝔䝮䛾PATHタᐃ䛜ᚲせ ■ C:HashiCorpVagrantbin ■ C:HashiCorpVagrantembeddedmingwbin ○ 䝁䝬䞁䝗䝥䝻䞁䝥䝖䛾௦䜟䜚䛻mingw32䛜౑⏝䛷䛝䜛䚹 ■ C:HashiCorpVagrantembeddedmingwmingw32env.cmd ● BOX䝣䜯䜲䝹 CentOS 7 ○ https://dl.dropboxusercontent.com/s/w3lbekm7eunrskm/centos-7.0-x86_64.box ○ CentOS7.0 x86_64 minimal + Puppet + VirtualBoxGuestAddtions 4.3.14
  • 12. ᳨ド⎔ቃ ● Vagrantfile䜢⦅㞟䛧䛶IP䜰䝗䝺䝇䜢๭䜚ᙜ䛶䛯 䝜䞊䝗䛷㉳ື䛥䛫䜎䛩䚹 ● Vagrantධ㛛䛾㈨ᩱ䜢ཧ↷䛧䛶ୗ䛥䛔䚹 ○ http://www.slideshare.net/ShinichiroOhhara/solavagrantver2
  • 13. ᳨ド⎔ቃ Virtual Box ⎔ቃ 䜽䝷䜲䜰䞁䝖ഃ Ubuntu 14.04 䝩䝇䝖PC 䝹䞊䝍䞊 192.168.33.1 䝃䞊䝞䞊ഃ CentOS7 192.168.33.70
  • 14. systemd ● 䝃䞊䝡䝇⟶⌮䛜systemd䜈ኚ᭦䛻䛺䜚䜎䛧䛯䚹 ○ 䝅䝇䝔䝮䛾㉳ື᫬䚸䝅䝱䝑䝖䝎䜴䞁᫬䛺䛹䚸䝃䞊䝡䝇䝥䝻 䝉䝇䛾⟶⌮䝅䝇䝔䝮䛜᪂䛧䛟䛺䜚䜎䛧䛯䚹 ● ᚑ᮶䛿UNIX⏤᮶䛾init䛻䛶⟶⌮ ○ UNIX䛾init䛻䛿䚸SystemV⣔䛸BSD⣔䛜䛒䜛 ○ RHEL5(CentOS5)䜎䛷䛿SysVinit ○ /etc/inittab䛻タᐃ䛥䜜䛯䝷䞁䝺䝧䝹䛷⟶⌮ ○ RHEL6(CentOS6)䛛䜙ubuntu䛸ྠ䛨Upstart ○ /etc/init/௨ୗ䛾タᐃ䝣䜯䜲䝹䛷⟶⌮ ○ Upstart䛿SysVinit஫᥮ ○ ஫᥮ᛶ䛾䛒䜛䝅䜵䝹䝇䜽䝸䝥䝖䛷ືస䜢タᐃ
  • 15. systemd ● init䜘䜚ኚ䜟䛳䛯䛣䛸 ○ Upstart䜘䜚୪ิᗘ䛾㧗䛔㧗㏿䛺㉳ື䛸⤊஢ ○ 䝅䜵䝹䝇䜽䝸䝥䝖䛷䛿䛺䛟タᐃ䝣䜯䜲䝹䛻䜘䜛⟶⌮ ○ 䝃䞊䝡䝇䝥䝻䝉䝇㉳ື䛜ᵝ䚻䛺᪉ἲ䛷ᰂ㌾䛻ฟ᮶䜛 ○ cgroups䛻䜘䜛䝃䞊䝡䝇䝥䝻䝉䝇䛾䝸䝋䞊䝇⟶⌮ ● Unit ○ 䝃䞊䝡䝇䝥䝻䝉䝇䛾タᐃ䝣䜯䜲䝹 ○ systemd䛜Unit䛾タᐃ䛷ฎ⌮䛩䜛䚹 ○ ௚䛾Unit䛸㐃ᦠ䠄౫Ꮡ䛸㉳ື㡰䠅䛧䛶ฎ⌮䛜ฟ᮶䜛䚹 ○ ᣑᙇᏊ䛻䜘䛳䛶ᵝ䚻䛺Unit䛾✀㢮䛜䛒䜛䚹 ○ タ⨨ሙᡤ䛿䚸/etc/systemd/system ○ 䜲䞁䝇䝖䞊䝹ึᮇタᐃ䛿䚸/usr/lib/systemd/system
  • 16. systemd ● 䝁䝬䞁䝗 ○ systemctl 䜸䝥䝅䝵䞁 Unitྡ ○ ᚑ᮶䛸ྠ䛨service䜒౑⏝䛷䛝䜎䛩䚹 ● 䝃䞊䝡䝇䝥䝻䝉䝇䛾㉳ື䛸೵Ṇ ○ Unit䛾ᣑᙇᏊ䛿䚸䛂.service䛃 ○ sytemctl [start/stop/restart] Unitྡ ○ reload䜸䝥䝅䝵䞁䛿Unit䛻ᐃ⩏䛥䜜䛶䛔䜛ሙྜ䛾䜏 ● Unitタᐃ䛾ኚ᭦ ○ Unitタᐃ䜢ኚ᭦䛧䛯᫬䛿䚸systemd䜈཯ᫎ䛥䛫䜎䛩䚹 ○ systemctl daemon-reload ● 䝥䝻䝉䝇䛾≧ែ☜ㄆ ○ systemctl status Unitྡ
  • 17. systemd ● ⮬ື㉳ື䛾タᐃ ○ systemctl [enable/disable] Unitྡ ○ Unit䛾㐃ᦠ䠄౫Ꮡ䠅タᐃ䛜ኚ᭦䛥䜜䜎䛩䚹 ○ Unitタᐃ䝣䜯䜲䝹䛷ᣦᐃ䛧䛯䛂WantedBy=䛃䝕䜱䝺䜽䝖䝸 䜈䛾䝅䞁䝪䝸䝑䜽䝸䞁䜽 ● Wants ○ 㐃ᦠ䠄౫Ꮡ䠅䛩䜛Unit䜢タᐃ䛧䜎䛩䚹 ○ Unitタᐃ䝣䜯䜲䝹䛾䛂Wants=䛃 ○ 䝕䜱䝺䜽䝖䝸䛂Unitྡ.wants䛃䜈䝅䞁䝪䝸䝑䜽䝸䞁䜽䜢సᡂ ● Requires ○ Wants䛿Unit㛫䛾ྠ᫬㉳ື䛜ኻᩋ䛧䛶䜒෌ᐇ⾜䛧䜎䛩䚹 ○ Requires䛿Unit㛫䛾ྠ᫬㉳ື䛜ኻᩋ䛧䛯䜙⤊஢䛧䜎 䛩䚹
  • 18. systemd ● ⮬ື㉳ື䛾☜ㄆ ○ systemctl list-unit-files --type=service ○ enabled䚷→䚷䛂Wants=䛃グ㍕䛒䜚䚸᭷ຠ ○ disabled䚷→䚷䛂Wants=䛃グ㍕䛒䜚䚸↓ຠ ○ static䚷→䚷䛂Wants=䛃グ㍕↓䛧 ● ⌧ᅾ䛾Unit≧ែ䛾☜ㄆ ○ systemctl list-units --type=service ○ list-units䜸䝥䝅䝵䞁䜢┬␎ฟ᮶䜛䚹 ● Unit䛾㐃ᦠ㛵ಀ䛾☜ㄆ ○ systemctl list-dependencies ○ 䝒䝸䞊⾲♧䛷㐃ᦠ䠄౫Ꮡ䛸㉳ື㡰䠅㛵ಀ䜢⾲♧䛩䜛䚹
  • 19. systemd ● target ○ 」ᩘ䛾Unit䜢䜎䛸䜑䛶䚸䜾䝹䞊䝥໬䛷䛝䜛䚹 ○ Unit䛾ᣑᙇᏊ䛿䚸䛂.target䛃 ○ 㛵ಀ䛩䜛」ᩘ䛾Unit䛾㐃ᦠ䠄౫Ꮡ䛸㉳ື㡰䠅䜢⟶⌮䚹 ○ target⮬య䛿ᐇ⾜䛧䛺䛔䚹 ○ ᚑ᮶䛾䝷䞁䝺䝧䝹䛜↓䛟䛺䜚䚸Unit䛾target䛻ኚ䜟䜚䜎䛧 䛯䚹 ○ ᚑ᮶䛾䝷䞁䝺䝧䝹0䛛䜙6䛸㐪䛔䚸⮬⏤䛻タᐃฟ᮶䜛䚹 ● 䝅䝇䝔䝮䛾㉳ື≧ែ䛾ኚ᭦᪉ἲ ○ /etc/systemd/system/default.target ○ 䝅䞁䝪䝸䝑䜽䝸䞁䜽ඛ䜢ኚ᭦䛩䜛䛣䛸䛷䚸䝷䞁䝺䝧䝹┦ᙜ 䜢ᐇ⌧䛧䛶䛔䜎䛩䚹
  • 20. systemd ● ᚑ᮶䛾䝷䞁䝺䝧䝹䛸䛾ᑐẚ ○ runlevel0䛛䜙runlevel6䛾䝅䞁䝪䝸䝑䜽䝸䞁䜽䜒䛒䜛䚹 ᚑ᮶䛾䝷䞁䝺䝧䝹 target䝣䜯䜲䝹ྡ ≧ែෆᐜ runlevel 䠌 poweroff.target ೵Ṇ runlevel 1 rescue.target 䝅䞁䜾䝹䝴䞊䝄䞊䝰䞊䝗 runlevel 2 multi-user.target 䝬䝹䝏䝴䞊䝄䞊䝰䞊䝗 runlevel 3 multi-user.target 䝬䝹䝏䝴䞊䝄䞊䝰䞊䝗 runlevel 4 multi-user.target 䝬䝹䝏䝴䞊䝄䞊䝰䞊䝗 runlevel 5 graphical.target GUI䝬䝹䝏䝴䞊䝄䞊䝰䞊䝗 runlevel 6 reboot.target ෌㉳ື
  • 21. systemd ● 䛭䛾௚䛾Unit ○ 䛂service䛃䛂target䛃䛾௚䛻䜒Unit䛾✀㢮䛜䛒䜚䜎䛩䚹 ● mount, swap ○ /etc/fstab䛛䜙⮬ືసᡂ䛥䜜䜎䛩䚹 ● device ○ 䝕䝞䜲䝇䛜ㄆ㆑䛩䜛䛸⮬ືసᡂ䛥䜜䜎䛩䚹 ● path ○ 䝟䝇䜢┘ど䛧䛶䚸䝣䜯䜲䝹䛻ᛂ䛨䛶䝃䞊䝡䝇䜢㉳ື䚹 ● socket ○ 䝋䜿䝑䝖䜢┘ど䛧䛶䚸᥋⥆䛻ᛂ䛨䛶䝃䞊䝡䝇䜢㉳ື䚹
  • 22. NetworkManager ● 䝛䝑䝖䝽䞊䜽䝕䝞䜲䝇タᐃ ○ /etc/sysconfig/network-scipts/䛻䛒䜛タᐃ䝣䜯䜲䝹䜢┤ ᥋⦅㞟䛩䜛䛾䛷䛿䛺䛟䚸NetworkManager䜢౑⏝䛩䜛䚹 ○ ᚑ᮶䛾タᐃ䝣䜯䜲䝹䜒฼⏝䛷䛝䜛䚹 ○ Ethernet䜲䞁䝍䞊䝣䜵䞊䝇䛿ᶆ‽䛷䛿↓ຠ䛻䛺䛳䛶䛔 䜛䚹 ● NetworkManager䝣䝻䞁䝖䜶䞁䝗 ○ GUI䛾GNOME⎔ቃ䛷᧯స䛧䜎䛩䚹 ● nmtui ○ 䝔䜻䝇䝖⏬㠃䛷ᑐヰⓗ䛻䝛䝑䝖䝽䞊䜽タᐃ䛧䜎䛩䚹
  • 23. NetworkManager ● nmcli ○ 䝁䝬䞁䝗䝷䜲䞁䛷䝛䝑䝖䝽䞊䜽タᐃ䛧䜎䛩䚹 ○ 䝃䞊䝞䞊⟶⌮⪅ྥ䛡䛻䚸䛣䛣䛷䛿nmcli䜢Ꮫ⩦䛧䜎䛩䚹 ● 䝩䝇䝖ྡ䛾ኚ᭦ ○ nmcli general hostname 䝩䝇䝖ྡ ○ bmcli g ho 䝩䝇䝖ྡ 䛸┬␎䛷䛝䜛䚹 ○ /etc/hostname䝣䜯䜲䝹䛻タᐃ䛥䜜䜛䚹
  • 24. NetworkManager ● nmcli device ○ ≀⌮䝕䝞䜲䝇䛾⟶⌮ ● 䝕䝞䜲䝇䛾୍ぴ ○ nmcli device ○ nmcli d 䛸┬␎ฟ᮶䜛䚹 ● 䝕䝞䜲䝇䛾ヲ⣽ ○ nmcli device show 䝕䝞䜲䝇ྡ ○ nmcli d s 䛸┬␎ฟ᮶䜛䚹
  • 25. NetworkManager ● nmcli connection ○ ᥋⥆タᐃ䛾⟶⌮ ● ᥋⥆≧ἣ䛾୍ぴ ○ nmcli connection ○ nmcli c 䛸┬␎䛷䛝䜛䚹 ○ nmcli --fields 㡯┠ connection 䛷᳨⣴⾲♧䜒ฟ᮶䜛䚹 ● ᥋⥆䛾ヲ⣽ ○ nmcli connection show ྡ๓䜒䛧䛟䛿UUID ○ nmcli c s ྡ๓䜒䛧䛟䛿UUID䚷䛸┬␎䛷䛝䜛䚹 ○ ྡ๓䛻䝇䝨䞊䝇䛜䛒䜛䛸䛝䛿䚸䛂”䛃䝎䝤䝹䜽䜷䞊䝔䞊䝅䝵 䞁䛷ᅖ䜣䛷ᣦᐃ䛩䜛䚹 ○ nmcli c s “Wired connection 1”
  • 26. NetworkManager ● ᥋⥆䛾᭷ຠ໬ ○ nmcli connection up ྡ๓䜒䛧䛟䛿UUID ● ᥋⥆䛾↓ຠ໬ ○ nmcli connection down ྡ๓䜒䛧䛟䛿UUID ● ᥋⥆䛾ືస☜ㄆ ○ nmcli c s ྡ๓䜒䛧䛟䛿UUID 䛷IP䜰䝗䝺䝇䜢☜ㄆ ○ ping 䛷␯㏻䜢☜ㄆ ○ nmcli c d ྡ๓䜒䛧䛟䛿UUID 䛷↓ຠ໬ ○ ping 䛷␯㏻ฟ᮶䛺䛔䛾䜢☜ㄆ ○ nmcli c u ྡ๓䜒䛧䛟䛿UUID 䛷᭷ຠ໬ ○ ping 䛷␯㏻䜢☜ㄆ
  • 27. NetworkManager ● タᐃ䛾ኚ᭦ ○ nmcli connection modify ྡ๓ 㡯┠ タᐃ್ ○ nmcli c m 䛸┬␎䛷䛝䜛䚹 ● IP䜰䝗䝺䝇䛸䝀䞊䝖䜴䜵䜲䛾ኚ᭦ ○ DHCP䜢ᡭືタᐃ䜈ኚ᭦䛧䜎䛩䚹 ○ nmcli c m ྡ๓ ipv4.method manual ○ nmcli c m ྡ๓ ipv4.addresses "IP䜰䝗䝺䝇/䝛䝑䝖䝬䝇 䜽 䝀䞊䝖䜴䜵䜲" ○ タᐃኚ᭦䛧䛯䛰䛡䛷䛿䚸タᐃ್䛿᭷ຠ䛻䛺䜙䛺䛔䚹 ○ ᥋⥆䜢down/up䛧䛯ᚋ䛷タᐃ್䛜᭷ຠ䛻䛺䜛䚹
  • 28. NetworkManager ● DNS䛾ኚ᭦ ○ nmcli c m ྡ๓ ipv4.dns "DNS䝃䞊䝞䞊䛾IP䜰䝗䝺䝇" ● タᐃ್䛾㏣ຍ䛸๐㝖 ○ ᪤Ꮡ䛾್䛻㏣ຍ䛩䜛ሙྜ䛿䚸㡯┠ྡ䛾๓䛻䛂䠇䛃䜢௜䛡 䜛䚹 ○ ᪤Ꮡ䛾್䛛䜙๐㝖䛩䜛ሙྜ䛿䚸㡯┠ྡ䛾๓䛻䛂䞊䛃䜢௜ 䛡䜛䚹 ○ nmcli c m ྡ๓ +㡯┠ྡ ್ ○ nmcli c m ྡ๓ -㡯┠ྡ ್ ● DHCP䛾タᐃ ○ nmcli c m ྡ๓ ipv4.method auto
  • 29. iproute2 ● 䝛䝑䝖䝽䞊䜽タᐃ䝁䝬䞁䝗䛾ኚ᭦ ○ 䝕䝞䜲䝇ྡ䛜䛂eth␒ྕ䛃䛛䜙䛂enྡ⛠䛃䜈ኚ᭦䛻䛺䜚䜎䛧 䛯䚹 ○ ᚑ᮶䛾ifconfig,route,arp,netstat䝁䝬䞁䝗䛿㠀᥎ዡ䚹 ○ ᶆ‽䛷䛿౑⏝䛷䛝䜎䛫䜣䚹 ○ ู㏵䚸net-tools䝟䝑䜿䞊䝆䜢䜲䞁䝇䝖䞊䝹䛩䜜䜀౑⏝ฟ ᮶䜎䛩䚹 ○ yum install net-tools ○ ᪂䛧䛔iproute2䝟䝑䜿䞊䝆䛾䝁䝬䞁䝗䜢᥎ዡ䛧䜎䛩䚹 ○ ྂ䛔䝁䝬䞁䝗䛿ᛀ䜜䛶᪂䛧䛔䝁䝬䞁䝗䜢Ꮫ⩦䛧䜎䛧䜗䛖䚹
  • 30. iproute2 ● ip addr show ○ ipconfig䛻┦ᙜ䛩䜛䝁䝬䞁䝗䚹 ○ 䝕䝞䜲䝇䛾䜰䝗䝺䝇䜢⾲♧䛩䜛䚹 ○ ฎ⌮䝟䜿䝑䝖䛾⤫ィ䛿⾲♧䛥䜜䛺䛔䚹 ● ip -s link ○ ipconfig䛻┦ᙜ䛩䜛䝁䝬䞁䝗䚹 ○ ᥋⥆䛾ฎ⌮䝟䜿䝑䝖䛾⤫ィ䜢⾲♧䛩䜛䚹 ● ip route ○ route䛻┦ᙜ䛩䜛䝁䝬䞁䝗䚹 ○ 䝹䞊䝔䜱䞁䜾䝔䞊䝤䝹䜢⾲♧䛩䜛䚹
  • 31. iproute2 ● ip neigh ○ arp䛻┦ᙜ䛩䜛䝁䝬䞁䝗䚹 ○ 䝕䝞䜲䝇䛾Mac䜰䝗䝺䝇䜢⾲♧䛩䜛䚹 ● ip䝁䝬䞁䝗 ○ ྛ䝛䝑䝖䝽䞊䜽タᐃ䜢ኚ᭦䛩䜛䛣䛸䛜ฟ᮶䜎䛩䚹 ○ 䝕䝞䜲䝇䜢down/up䛩䜛஦↓䛟䚸タᐃ䛿༶཯ᫎ䛧䜎䛩䚹 ○ タᐃ್䛿ಖᏑ䛥䜜䜎䛫䜣䚹 ● ss ○ netstat䛻┦ᙜ䛩䜛䝁䝬䞁䝗䚹 ○ 䝃䞊䝡䝇䛾౑⏝≧ἣ䜢⾲♧䛩䜛䚹