Configuring Net HDD using SAMBA fails
I have created a share on windows 10 machine. I have tested that I can access that folder from another machine using user name and password and it worked. I was able to create a file in that share from another machine by running
echo "hi" > a.txt
But when I attempted to add the same folder as Net HDD it failed.
The I decided to try linux samba.
Here's how I created it
podman run -it --name samba -p 139:139 -p 445:445 \
-v /var/home/user/Documents/scans:/mount:z \
-d dperson/samba -p \
-u "example1;badpass" \
-s "public;/mount/share42" \
-s "sharescans42;/mount/scans42;no;no;no;example1" \
-w "sambad21"
Here's how I tested from another ubuntu
ubuntu@ubuntu:~$ smbclient //192.168.1.112/sharescans42 -U example1%badpass
Try "help" to get a list of possible commands.
smb: \> ls
. D 0 Thu May 9 00:00:37 2024
.. D 0 Wed May 8 23:55:41 2024
a.txt A 3 Thu May 9 00:00:37 2024
498426880 blocks of size 1024. 85497836 blocks available
smb: \>
Then I went to
Configuration -> Storage -> Storage Management - Net HDD
I have added server. specified 192.168.1.112 and also specified in path `sharescans42`
User name used: "example1" and the password I specified `badpass`
Clicked test and got in the bottom corner a container displaying next error:
Mounting to NAS server failed. Invalid directory or incorrect user name/password.
I opened Chrome dev tools and decided to capture a bit more what's going on. What might help you explain what I'm doing wrong.
Here's the payload when click "test" button which browser send for the request
Payload
<?xml version: "1.0" encoding="UTF-8"?><nasTestDescription><addressingFormatType>ipaddress</addressingFormatType><ipAddress>192.168.1.112</ipAddress><path>sharescans42</path><nasType>NFS</nasType><mountType>SMB/CIFS</mountType><userName>6200bad26718d52e8fd12ee3f9a20885</userName><password>7a3f5cafb562099cd436ed056ed16628</password></nasTestDescription>
Here's the response which browser gets for the request
<?xml version="1.0" encoding="UTF-8"?>
<nasTestResult version="2.0" xmlns="http://www.std-cgi.com/ver20/XMLSchema">
<errorCode>152</errorCode>
<errorDescription>no nas directory</errorDescription>
</nasTestResult>
What am I doing wrong?
-
Annke webcams need NT1 protocol, I fixed the same issue with this line in the `smb.conf`:
server min protocol = NT1
See https://www.samba.org/samba/docs/current/man-html/smb.conf.5.html#SERVERMINPROTOCOL
Please sign in to leave a comment.
Comments
1 comment