system administration hw2 - ftp, samba, bt, zfs jwbai
TRANSCRIPT
![Page 1: System Administration HW2 - FTP, Samba, BT, ZFS jwbai](https://reader035.vdocuments.net/reader035/viewer/2022071716/56649e435503460f94b36342/html5/thumbnails/1.jpg)
System Administration HW2System Administration HW2- FTP, Samba, BT, ZFS- FTP, Samba, BT, ZFS
jwbai
![Page 2: System Administration HW2 - FTP, Samba, BT, ZFS jwbai](https://reader035.vdocuments.net/reader035/viewer/2022071716/56649e435503460f94b36342/html5/thumbnails/2.jpg)
Com
pu
ter C
en
ter, C
S, N
CTU
2
FTPFTP
Install a FTP server for FreeBSD• Pure-FTPd: /usr/ports/ftp/pure-ftpd/
• ProFTPD: /usr/ports/ftp/proftpd/
Settings
1. Anonymous Login Chrooted (/home/ftp is your root directory) Can download from /home/ftp/public Can upload & mkdir but no download or delete
from /home/ftp/upload Hidden directory /home/ftp/hidden
There is a directory called “treasure” inside Client can’t list in /home/ftp/hidden/ but can in hidden/treasure
![Page 3: System Administration HW2 - FTP, Samba, BT, ZFS jwbai](https://reader035.vdocuments.net/reader035/viewer/2022071716/56649e435503460f94b36342/html5/thumbnails/3.jpg)
Com
pu
ter C
en
ter, C
S, N
CTU
3
FTP FTP
Settings (cont’d)
2. Create a system user “sysadm” (2%) Could login by ssh Password is your student id
3. Create a virtual user “ftp-vip” Chrooted (/home/ftp is your root directory) Password is your student-id Can login from 140.113.17.225 & your ip only Full access to /home/ftp Hidden directory is visible to ftp-vip
![Page 4: System Administration HW2 - FTP, Samba, BT, ZFS jwbai](https://reader035.vdocuments.net/reader035/viewer/2022071716/56649e435503460f94b36342/html5/thumbnails/4.jpg)
Com
pu
ter C
en
ter, C
S, N
CTU
4
SambaSamba
Install Samba• /usr/ports/net/samba34
• /usr/ports/net/samba35
Share a directory on FreeBSD as normal Windows folders• Windows user can direct access (drag & drop) files on FreeBSD via 網路芳鄰 , but only owner can read/write files.
• Admin can read/write all files
• .exe .bin .vbs could not upload
• Guest account could browse
• FreeBSD mount windows partition
![Page 5: System Administration HW2 - FTP, Samba, BT, ZFS jwbai](https://reader035.vdocuments.net/reader035/viewer/2022071716/56649e435503460f94b36342/html5/thumbnails/5.jpg)
Com
pu
ter C
en
ter, C
S, N
CTU
5
BTBT
What is BT?• Bit Torrent
a peer-to-peer (P2P) communications protocol for file sharing.
Install a BT client for FreeBSD• You can choose a BT client from /usr/ports/net-p2p
Download a torrent file, and the BT client on FreeBSD can automatically start download• Put the torrent file on FreeBSD.
(you can use samba or ftp)
• Monitor directory
![Page 6: System Administration HW2 - FTP, Samba, BT, ZFS jwbai](https://reader035.vdocuments.net/reader035/viewer/2022071716/56649e435503460f94b36342/html5/thumbnails/6.jpg)
Com
pu
ter C
en
ter, C
S, N
CTU
6
ZFSZFS
Create a zfs file system with raidz or mirror Do zfs snapshot Do zfs rollback Set compression Reboot and everything is fine (zfs still mount)
![Page 7: System Administration HW2 - FTP, Samba, BT, ZFS jwbai](https://reader035.vdocuments.net/reader035/viewer/2022071716/56649e435503460f94b36342/html5/thumbnails/7.jpg)
Com
pu
ter C
en
ter, C
S, N
CTU
7
How to hand inHow to hand in
DEMO
![Page 8: System Administration HW2 - FTP, Samba, BT, ZFS jwbai](https://reader035.vdocuments.net/reader035/viewer/2022071716/56649e435503460f94b36342/html5/thumbnails/8.jpg)
Com
pu
ter C
en
ter, C
S, N
CTU
8
DeadlineDeadline
2010/11/09 18:00 You do not need to submit anything
![Page 9: System Administration HW2 - FTP, Samba, BT, ZFS jwbai](https://reader035.vdocuments.net/reader035/viewer/2022071716/56649e435503460f94b36342/html5/thumbnails/9.jpg)
Com
pu
ter C
en
ter, C
S, N
CTU
9
HelpHelp
IRC channel #nctuNASA on freenode Newsgroup cs.course.sysadmin BBS bs2.to board CS-SysAdmin Email [email protected] Goto CSCC to ask professional 3F!