[Linux] 安裝samba

來源:互聯網
上載者:User
安裝samba一、RPM安裝包1、首先驗證您的機器中是否已經安裝samba==================================rpm -qa|grep samba,如果出現下面提示則表示samba已經安裝完畢samba-client-2.2.8a-13mdksamba-common-2.2.8a-13mdksamba-server-2.2.8a-13mdk2、如果服務存在的話先停止服務再卸載# service smb stoprpm -e samba-server-2.2.8a-13mdkrpm -e samba-common-2.2.8a-13mdkrpm -e samba-client-2.2.8a-13mdk如果空間不夠可以刪除日誌cd var/logrm -rf *3、安裝服務rpm -ivh samba-winbind-2.2.8a-13mdk.i586.rpm或#rpm -ivh samba*.rpm –nodeps –force==================================二、源碼安裝下載包,mkdir /home/kingsoft/sambacd  /home/kingsoft/sambatar zxvf samba-3.5.5.tar.gz#尋找configure 檔案所在路徑find . -name configure  #configure進入所在目錄cd ./samba-3.5.5/source3./configuremake & make install4、修改/etc/samba/smb.conf[public]   path = /usr/somewhere/else/public   public = yes   valid user = kingsoft   writable = yes   printable = no5、啟動服務添加linux使用者:groupadd usersuseradd aa -g userspasswd aa刪除使用者:vi /etc/smbpasswd 添加了SMB使用者: smbpasswd -a aa如果目錄許可權有問題:id aa改變所有者:chown aa:users /usr/somewhere/else/public或改變許可權:chmod 777 aaservice smb start或service smb restart或#/etc/rc.d/init.d/smb start6、查看交換區大小free,查看磁碟空間 df修改交換區dd if=/dev/zero of=tmpswap bs=1k count=1500000chmod 600 tmpswapmkswap tmpswapswapon tmpswapa.切換成root使用者b.在/home/xmission目錄下,執行:swapon tmpswapc.改 /etc/rc 檔案:/sbin/swapon /home/xmission/tmpswapd.用xmission使用者啟動 gameserver(linux)以上操作在實際使用時xmission使用者要換成相應使用者7.搜尋安裝路徑whereis sambasamba共用中文檔案名稱亂碼的問題解決:開啟smb.conf 添加: display charset = cp936 unix charset = cp936 dos  charset = cp936重啟samba服務就OK了centos設定samba服務自啟動最簡單的方法如下chkconfig --level 2345 smb on

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.