Smbclient
NRDStor can be accessed using the smbclient
command-line utility.
Install Smbclient¶
You can download smbclient from https://www.samba.org/samba/download/.
Accessing and Managing Files¶
Once smbclient is installed, you can use smbclient
commands to navigate directories and manage files. Here are a few examples:
Accessing Files¶
To access a specific directory and retrieve a file, use the following command:
smbclient \\\\nrdstor.unl.edu\\nrdstor -U <campusName>/<UniversityUsername> -c "cd <groupname>/<username>/; get readme.txt"
In this command:
-
\\\\nrdstor.unl.edu\\nrdstor
: The path to the NRDStor server. -
-U <campusName>/<UniversityUsername>
: Your login credentials, wherecampusName
corresponds to your campus andUniversityUsername
is your specific NU user name.
Note
The <campusName>/<UniversityUsername>
values to use depend on which campus you are associated with. Users from UNL, UNK, and UNO may use their local campus credentials. Users from UNMC must use their NUID username and password. Refer to the following table:
Campus | Campus Login | SMB_Campus_Identifer |
---|---|---|
UNL | husker@unl.edu | UNL-AD/husker |
UNO | maverick@unomaha.edu | UNOMAHA/maverick |
UNK | loper@unk.edu | UNKNET/loper |
UNMC (via NUID) | 00000000 (NUID) | NEAD/00000000 |
In the examples provided here, please replace <campusName>/<UniversityUsername>
with the value from the SMB_Campus_Identifer column in the table, and the respective NU username/ID.
-
-c "cd <groupname>/<username>/; get readme.txt"
: This-c
option passes a command string tosmbclient
. -
cd <groupname>/<username>/
: The command to change the directory.groupname
is the name of your HCC group, andusername
is your HCC username. -
get readme.txt
: get the filereadme.txt
.
Uploading Files¶
To upload a file to a specific directory, use the following command:
smbclient \\\\nrdstor.unl.edu\\nrdstor -U <campusName>/<UniversityUsername> -c "cd <groupname>/<username>/; put readme.txt"
In the command string:
put readme.txt
: The command to upload the filereadme.txt
to the specified directory.
Downloading Full Directory¶
To download a specific directory from the server, use the following command:
smbclient \\\\nrdstor.unl.edu\\nrdstor -U <campusName>/<UniversityUsername> -c "recurse; prompt OFF; cd <groupname>/<username>/; mget directory_name"
In the command string "recurse; prompt OFF; cd <groupname>/<username>/; mget directory_name"
:
-
recurse
: Ensures that the command will operate recursively, affecting all subdirectories and their contents. -
prompt OFF
: Turns off prompting to confirm each file transfer. -
cd <groupname>/<username>/
: Changes the directory on the remote server to the specified path. -
mget directory_name
: Downloads the directory nameddirectory_name
from the server.
Uploading Full Directory¶
To upload a specific directory to the server, use the following command:
smbclient \\\\nrdstor.unl.edu\\nrdstor -U <campusName>/<UniversityUsername> -c "recurse; prompt OFF; cd <groupname>/<username>/; mput directory_name"
In the command string "recurse; prompt OFF; cd <groupname>/<username>/; mput directory_name"
:
mput directory_name
: Uploads the directory nameddirectory_name
to the server.