最近要在電腦教室使用mint18mate桌面安裝DRBL無碟環境,
一開始參考DRBL官方網站的安裝 http://drbl.nchc.org.tw/one4all/desktop/,修改/etc/network/interfaces,並且安裝環境,
(圖片來自鳥哥的私房菜)
安裝drbl過程中,我移除了幾個套件apt-get purge mintupdate mintupload mintinstall gparted mate-screensaver-common virtualbox-* network-manager* gnome-keyring cinnamon-session
但是,這間電腦教室的switch雖然是giga網速的,但數量卻是24port x 2台。
第一次,用鎖定學生電腦MAC address的方式,一台switch使用2個網域,但是效能太差;
第二次,一樣鎖定MAC,改用主機一張網卡負責20台電腦,主機其中2張網卡負擔太重,剩下2張網卡閒置,也不理想。
之後,在鳥哥的私房菜看到『透過 Linux bonding 技術合併多張網卡的頻寬』http://linux.vbird.org/linux_enterprise/0110network.php#server_bonding
1.設定bonding 參考 http://maxubuntu.blogspot.tw/2012/10/6-nic-bonding-debain-gnulinux.html
apt-get install ifenslave |
修改/etc/network/interfaces,伺服器有5張網卡,每2張各用一組bonding mode6,剩下那張對外(PS:這台主機使用auto會出問題,所以改成allow-hotplug )
# interfaces(5) file used by ifup(8) and ifdown(8) allow-hotplug enp1s0f0 allow-hotplug enp1s0f1 auto bond0 allow-hotplug enp1s0f2 allow-hotplug enp1s0f3 auto bond1 allow-hotplug eno1 |
然後,重新啟動網路,應該就能完成bonding。
2.加強NFS效能
a.參考http://eric0703.pentaxfans.net/2558,修改/etc/default/nfs-kernel-server,將RPCNFSDCOUNT 設大,我的伺服器最高好像只能設到RPCNFSDCOUNT=82
b.修改 /etc/sysctl.conf,加入以下這幾行
net.core.wmem_max=16777216 |
c.參考https://blog.breunig.xyz/2013/10/13/setting-up-nfs-cache-on-debian.html,安裝fscache
apt-get install cachefilesd |
修改/etc/default/cachefilesd,改RUN=yes,啟動fscache。
d.修改drbl設定,讓學生機掛載NFS時,加入fsc參數
修改/etc/drbl/drbl.conf ,尋找並修改成
# Extra options for NFS client in /etc/fstab |
3.重新安裝DRBL。