samba 3.0

Unable to find the Domain Master Browser name

# tail -f /var/log/messages
----
Unable to find the Domain Master Browser name ワークグループ名<1b> for the workgroup ワークグループ名.
Unable to sync browse lists in this workgroup.
----
# vi /etc/samba/smb.conf
----
local master = yes
domain master = yes 
preferred master = auto
wins support = yes
os level = 20
----
# service smb restart

Unable to connect to CUPS server

HDD増設

  1. 現在の情報表示
    # fdisk -l
    
    Disk /dev/hda: 122.9 GB, 122942324736 bytes
    255 heads, 63 sectors/track, 14946 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    
       Device Boot      Start         End      Blocks   Id  System
    /dev/hda1   *           1          13      104391   83  Linux
    /dev/hda2              14       14946   119949322+  8e  Linux LVM
    ...
    Disk /dev/hdb: 300.0 GB, 300090728448 bytes
    ...
    Disk /dev/hdd: 61.4 GB, 61492838400 bytes
  2. 領域確保
    # fdisk /dev/hdb
    # fdisk /dev/hdd
  3. フォーマット
    # mkfs.ext3 /dev/hdb1
    # mkfs.ext3 /dev/hdd1
  4. マウント
    # mkdir /mnt/samba
    # mkdir /mnt/backup
    # mount -t ext3 /dev/hdb1 /mnt/samba
    # mount -t ext3 /dev/hdd1 /mnt/backup
  5. fstabに追加
    # vi /etc/fstab
    ---------------------
    /dev/hdb1               /mnt/samba              ext3    defaults        1 2     
    /dev/hdd1               /mnt/backup             ext3    defaults        1 2     
    ---------------------

samba設定

  password server = example-fsv
  encrypt passwords = yes

  local master = yes

  wins support = yes

  dns proxy = no

  add user script = /usr/sbin/useradd -d /mnt/samba/home/%u -g samba -s /bin/false -m -k /mnt/samba/etc/skel %u;chmod 755 /mnt/samba/home/%u;
 delete user script = /usr/sbin/userdel %u

[homes]
  comment = Home Directories
  browseable = no
  writable = yes
  recycle:repository = .recycle
  recycle:keeptree = yes
  recycle:versions = yes
  recycle:touch = yes
  recycle:maxsize = 0
  recycle:exclude = *.tmp *.temp *.o *.obj ~$* *.~??
  recycle:exclude_dir = /tmp|/cache
# recycle:noversions = *.doc *.xls *.ppt

[public]
   comment = Public Stuff
   path = /mnt/samba/home
   writable = yes
   printable = no
   recycle:repository = .recycle/%u
   recycle:keeptree = yes
   recycle:versions = yes
   recycle:touch = yes
   recycle:maxsize = 0
   recycle:exclude = *.tmp *.temp *.o *.obj ~$* *.~??
   recycle:exclude_dir = /tmp|/cache
;   recycle:noversions = *.doc *.xls *.ppt
;   public = yes
;   write list = @staff
--------------------------------------------

ごみ箱の中身を定期的に削除

# vi /etc/cron.weekly/samba_recyclewatch
------------------------------------
#!/bin/bash

samba_home="/mnt/samba/home"
delete_hours=168

for user in `/bin/ls $samba_home`
do
  if [ -d "$samba_home/$user/.recycle" ]
  then
    /usr/sbin/tmpwatch -a -f $delete_hours "$samba_home/$user/.recycle"
    for D in `find "$samba_home/$user/.recycle" -type d | sort -r ` ; do echo $D ;rmdir $D ; done
  fi
done

/usr/sbin/tmpwatch -a -f $delete_hours "$samba_home/.recycle"
for D in `find "$samba_home/.recycle" -type d | sort -r ` ; do echo $D ;rmdir $D ; done
------------------------------------
# chmod 755 /etc/cron.weekly/samba_recyclewatch

Error writing 4 bytes to client. -1.

転送終了時に以下のエラーが/var/log/messageに記録されている。どうやら、クライアントがメッセンジャーサービスに対応していないと出る模様。無視して構わないみたい。

Error writing 4 bytes to client. -1.

リンク


トップ   編集 凍結 差分 バックアップ 添付 複製 名前変更 リロード   新規 一覧 検索 最終更新   ヘルプ   最終更新のRSS
Last-modified: 2018-09-15 (土) 07:31:38