Linux SMB Mount via Command Line Bash Shell

  1. Install smbfs to include these functions
    1. smbmount
    2. smbunmount
  2. Here is a demonstration of smbmount to mount an SMB share called “testshare” from a machine called “smbserver”:
    [root@linux1]# smbmount "\\\\smbserver\\testshare" -U username -c 'mount /testshare -u 500 -g 100' Added interface ip= bcast= nmask= Got a positive name query response from ( ) Password: ************* Domain=[KIMCONNECT] OS=[Unix] Server=[Samba 2.0.3] security=user
  3. Check the mounts
    root@linux1]# mount                                                                                                    
    /dev/hda2 on / type ext2 (rw)
    none on /proc type proc (rw)
    none on /dev/pts type devpts (rw,mode=622)
    //smbserver/testshare on /testshare type smbfs (0)
Posted on Categories Linux

Leave a Reply

Your email address will not be published. Required fields are marked *