Accessing Samba Shares From an Oracle Linux Client
To access a Samba share from an Oracle Linux host, install the following packages:
-
samba-clientInstalling the
samba-clientpackage gives you thesmbclientutility that provides SFTP-like commands to access Samba shares. For example,smbclientprovides agetcommand for downloading a file from a remote Samba share, and aputcommand for uploading a file. -
cifs-utilsInstalling the
cifs-utilspackage lets you mount a Samba share.
Using smbclient Commands
The following steps give a brief overview of how you might use the
smbclient commands:
-
Log onto a share example_samba_share hosted on server example_samba_server using account EXAMPLE.COM/user1:
sudo smbclient -U "EXAMPLE.COM\user1" //example_samba_server/example_samba_share -
Change to directory location /directory1/ :
smb: \> cd /directory1/ -
Download file ExampleFile.txt:
smb: \directory1\> get ExampleFile.txt -
End the session:
smb: \directory1\> exit
For more information, see the smbclient(1) manual page.