Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I'm trying to automount a network share when the system boots up or the user login. The network share is a external hard disk attached to a DSL home router.

I can mount it manually from Nautilus with the URL: smb://livebox/DiscosUSB/

However, I cannot mount with mount.cifs. I have tried this different sec parameters, with errors 95 and 56 on each case:

root@ubuntu:~# mount.cifs //livebox/DiscosUSB/ /mnt/zeta --verbose -o guest,sec=ntlm

mount.cifs kernel mount options: ip=192.168.2.1,unc=\\livebox\DiscosUSB,guest,sec=ntlm,user=,pass=********
mount error(95): Operation not supported
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)

root@ubuntu:~# mount.cifs //livebox/DiscosUSB/ /mnt/zeta --verbose -o guest,sec=none

mount.cifs kernel mount options: ip=192.168.2.1,unc=\\livebox\DiscosUSB,guest,sec=none,user=,pass=********
mount error(56): Invalid request code
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)

If I write a 7 into /proc/fs/cifs/cifsFYI, I can see the following on dmesg:

[12029.193190] /build/buildd/linux-3.8.0/fs/cifs/cifsfs.c: Devname: //livebox/DiscosUSB/ flags: 0 
[12029.193244] /build/buildd/linux-3.8.0/fs/cifs/connect.c: Anonymous login
[12029.193252] /build/buildd/linux-3.8.0/fs/cifs/connect.c: file mode: 0x1ed  dir mode: 0x1ed
[12029.193393] /build/buildd/linux-3.8.0/fs/cifs/connect.c: CIFS VFS: in cifs_mount as Xid: 180 with uid: 0
[12029.193397] /build/buildd/linux-3.8.0/fs/cifs/connect.c: UNC: \\livebox\DiscosUSB
[12029.193428] /build/buildd/linux-3.8.0/fs/cifs/connect.c: Socket created
[12029.193433] /build/buildd/linux-3.8.0/fs/cifs/connect.c: sndbuf 16384 rcvbuf 87380 rcvtimeo 0x6d6
[12029.194309] /build/buildd/linux-3.8.0/fs/cifs/fscache.c: cifs_fscache_get_client_cookie: (0xffff880053125800/0xffff
[12029.194319] /build/buildd/linux-3.8.0/fs/cifs/connect.c: CIFS VFS: in cifs_get_smb_ses as Xid: 181 with uid: 0
[12029.194322] /build/buildd/linux-3.8.0/fs/cifs/connect.c: Existing smb sess not found
[12029.194335] /build/buildd/linux-3.8.0/fs/cifs/cifssmb.c: secFlags 0x2
[12029.194342] /build/buildd/linux-3.8.0/fs/cifs/transport.c: For smb_command 114
[12029.194347] /build/buildd/linux-3.8.0/fs/cifs/transport.c: Sending smb: smb_len=78
[12029.194612] /build/buildd/linux-3.8.0/fs/cifs/connect.c: Demultiplex PID: 9072
[12029.195740] /build/buildd/linux-3.8.0/fs/cifs/connect.c: RFC1002 header 0x7f
[12029.195791] /build/buildd/linux-3.8.0/fs/cifs/transport.c: cifs_sync_mid_result: cmd=114 mid=1 state=4
[12029.195801] /build/buildd/linux-3.8.0/fs/cifs/cifssmb.c: Dialect: 2
[12029.195811] /build/buildd/linux-3.8.0/fs/cifs/asn1.c: OID len = 10 oid = 0x1 0x3 0x6 0x1
[12029.195814] /build/buildd/linux-3.8.0/fs/cifs/cifssmb.c: Signing disabled
[12029.195819] /build/buildd/linux-3.8.0/fs/cifs/cifssmb.c: negprot rc -95
[12029.195825] /build/buildd/linux-3.8.0/fs/cifs/connect.c: CIFS VFS: leaving cifs_get_smb_ses (xid = 181) rc = -95
[12029.195845] /build/buildd/linux-3.8.0/fs/cifs/fscache.c: cifs_fscache_release_client_cookie: (0xffff880053125800/0x
[12029.196068] /build/buildd/linux-3.8.0/fs/cifs/connect.c: CIFS VFS: leaving cifs_mount (xid = 180) rc = -95
[12029.196072] CIFS VFS: cifs_mount failed w/return code = -95

An for the second try:

[12043.752256] /build/buildd/linux-3.8.0/fs/cifs/cifsfs.c: Devname: //livebox/DiscosUSB/ flags: 0 
[12043.752301] /build/buildd/linux-3.8.0/fs/cifs/connect.c: Anonymous login
[12043.752308] /build/buildd/linux-3.8.0/fs/cifs/connect.c: file mode: 0x1ed  dir mode: 0x1ed
[12043.752430] /build/buildd/linux-3.8.0/fs/cifs/connect.c: CIFS VFS: in cifs_mount as Xid: 182 with uid: 0
[12043.752434] /build/buildd/linux-3.8.0/fs/cifs/connect.c: UNC: \\livebox\DiscosUSB
[12043.752469] /build/buildd/linux-3.8.0/fs/cifs/connect.c: Socket created
[12043.752474] /build/buildd/linux-3.8.0/fs/cifs/connect.c: sndbuf 16384 rcvbuf 87380 rcvtimeo 0x6d6
[12043.752854] /build/buildd/linux-3.8.0/fs/cifs/fscache.c: cifs_fscache_get_client_cookie: (0xffff880053124000/0xffff
[12043.752862] /build/buildd/linux-3.8.0/fs/cifs/connect.c: CIFS VFS: in cifs_get_smb_ses as Xid: 183 with uid: 0
[12043.752865] /build/buildd/linux-3.8.0/fs/cifs/connect.c: Existing smb sess not found
[12043.752877] /build/buildd/linux-3.8.0/fs/cifs/cifssmb.c: secFlags 0x81
[12043.752881] /build/buildd/linux-3.8.0/fs/cifs/cifssmb.c: NTLMSSP only mechanism, enable extended security
[12043.752887] /build/buildd/linux-3.8.0/fs/cifs/transport.c: For smb_command 114
[12043.752891] /build/buildd/linux-3.8.0/fs/cifs/transport.c: Sending smb: smb_len=78
[12043.752928] /build/buildd/linux-3.8.0/fs/cifs/connect.c: Demultiplex PID: 9075
[12043.754068] /build/buildd/linux-3.8.0/fs/cifs/connect.c: RFC1002 header 0x7f
[12043.754091] /build/buildd/linux-3.8.0/fs/cifs/transport.c: cifs_sync_mid_result: cmd=114 mid=1 state=4
[12043.754097] /build/buildd/linux-3.8.0/fs/cifs/cifssmb.c: Dialect: 2
[12043.754106] /build/buildd/linux-3.8.0/fs/cifs/asn1.c: OID len = 10 oid = 0x1 0x3 0x6 0x1
[12043.754110] /build/buildd/linux-3.8.0/fs/cifs/cifssmb.c: negprot rc 0
[12043.754115] /build/buildd/linux-3.8.0/fs/cifs/connect.c: Security Mode: 0x3 Capabilities: 0x8000a27d TimeAdjust: -7
[12043.754119] /build/buildd/linux-3.8.0/fs/cifs/sess.c: sess setup type 3
[12043.754193] /build/buildd/linux-3.8.0/fs/cifs/sess.c: ntlmssp session setup phase 1
[12043.754200] /build/buildd/linux-3.8.0/fs/cifs/transport.c: For smb_command 115
[12043.754203] /build/buildd/linux-3.8.0/fs/cifs/transport.c: Sending smb: smb_len=206
[12043.754730] /build/buildd/linux-3.8.0/fs/cifs/connect.c: RFC1002 header 0x23
[12043.754748] /build/buildd/linux-3.8.0/fs/cifs/transport.c: cifs_sync_mid_result: cmd=115 mid=2 state=4
[12043.754754] /build/buildd/linux-3.8.0/fs/cifs/netmisc.c: Mapping smb error code 0x400002 to POSIX err -56
[12043.754758] /build/buildd/linux-3.8.0/fs/cifs/misc.c: Null buffer passed to cifs_small_buf_release
[12043.754762] /build/buildd/linux-3.8.0/fs/cifs/sess.c: ssetup freeing small buf ffff88001c491e00
[12043.754766] CIFS VFS: Send error in SessSetup = -56
[12043.754772] /build/buildd/linux-3.8.0/fs/cifs/connect.c: CIFS VFS: leaving cifs_get_smb_ses (xid = 183) rc = -56
[12043.754782] /build/buildd/linux-3.8.0/fs/cifs/fscache.c: cifs_fscache_release_client_cookie: (0xffff880053124000/0x
[12043.754905] /build/buildd/linux-3.8.0/fs/cifs/connect.c: CIFS VFS: leaving cifs_mount (xid = 182) rc = -56
[12043.754910] CIFS VFS: cifs_mount failed w/return code = -56

What is happening here?

share|improve this question
    
Question algo posted on: answers.launchpad.net/ubuntu/+question/232372 –  AntonioGM Jul 13 '13 at 23:26
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.