Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Creating snapshot over SMB does not work - Kernel OOPS #885

Closed
niekbergboer opened this issue Aug 23, 2012 · 1 comment
Closed

Creating snapshot over SMB does not work - Kernel OOPS #885

niekbergboer opened this issue Aug 23, 2012 · 1 comment
Milestone

Comments

@niekbergboer
Copy link

Symptom:
When creating a snapshot by mkdir'ing a dir in the .zfs/snapshot directory, this works locally, but not over SMB - That creates a kernel OOPS.

Steps to reproduce:

  1. zfs create tank/testfs
  2. zfs set snapdir=visible tank/testfs
  3. mkdir /tank/testfs/.zfs/snapshot/mysnapshotname <= succesfully creates a snapshot
  4. Share /tank/testfs over SMB, zfs allow -u username snapshot tank/testfs
  5. Connect to SMB server from windows machine (other type of machine will work, too)
  6. (on windows): net use \server\share x:
  7. (on windows): mkdir x:.zfs\snapshot\othernsnapshotname

Step 7. fails to create a snapshot; client tells me that the network location is no longer available, server gets a lot of smoke and sparks in its kernel log:

[ 132.586072] BUG: unable to handle kernel NULL pointer dereference at 000000000000005f
[ 132.586209] IP: [] follow_managed+0x35/0x140
[ 132.586292] PGD 0
[ 132.586368] Oops: 0000 [#7] SMP
[ 132.586475] CPU 7
[ 132.586508] Modules linked in: dm_crypt i7core_edac serio_raw edac_core mac_hid lp parport zfs(P) zcommon(P) znvpair(P) zavl(P) zunicode(P) spl(O) zlib_deflate multipath linear aacraid 3w_9xxx 3w_xxxx raid10 raid456 async_pq async_xor xor async_memcpy async_raid6_recov raid6_pq async_tx raid0 sata_nv sata_sil sata_via raid1 nouveau r8169 ttm drm_kms_helper drm i2c_algo_bit mxm_wmi video wmi
[ 132.588061]
[ 132.588105] Pid: 2334, comm: smbd Tainted: P D O 3.2.0-29-generic #46-Ubuntu MSI MS-7522/MSI X58 Pro-E (MS-7522)
[ 132.588265] RIP: 0010:[] [] follow_managed+0x35/0x140
[ 132.588361] RSP: 0018:ffff88031857dc08 EFLAGS: 00010246
[ 132.588410] RAX: 000000000000005f RBX: ffff88031857dd18 RCX: ffff880322723900
[ 132.588462] RDX: 0000000000000000 RSI: 0000000000000001 RDI: 000000000000005f
[ 132.588514] RBP: ffff88031857dc58 R08: ffffffff8118cffb R09: 0000000000000000
[ 132.588566] R10: 0000000000000000 R11: 000000000000000b R12: ffff880322723900
[ 132.588618] R13: 0000000000000001 R14: 0000000000000001 R15: 0000000000000000
[ 132.588670] FS: 00007f2d65021740(0000) GS:ffff88033fce0000(0000) knlGS:0000000000000000
[ 132.588735] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[ 132.588785] CR2: 000000000000005f CR3: 0000000326591000 CR4: 00000000000006e0
[ 132.588837] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
[ 132.589558] DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400
[ 132.589610] Process smbd (pid: 2334, threadinfo ffff88031857c000, task ffff88032606c500)
[ 132.589674] Stack:
[ 132.589719] 0000000000000001 ffff88031857dd40 ffff88031857dc58 00ffffff81182770
[ 132.589904] ffff88031857dc58 ffff88031857ddc8 ffff88031857dd18 000000000000005f
[ 132.590089] 0000000000000001 ffff88031857dd40 ffff88031857dcd8 ffffffff8118481d
[ 132.590273] Call Trace:
[ 132.590320] [] do_lookup+0x14d/0x310
[ 132.590371] [] ? __pollwait+0xf0/0xf0
[ 132.590421] [] path_lookupat+0x11c/0x750
[ 132.590471] [] do_path_lookup+0x31/0xc0
[ 132.590521] [] user_path_at_empty+0x59/0xa0
[ 132.590572] [] ? do_sync_read+0xda/0x120
[ 132.590623] [] user_path_at+0x11/0x20
[ 132.590673] [] vfs_fstatat+0x3a/0x70
[ 132.590723] [] vfs_stat+0x1b/0x20
[ 132.590773] [] sys_newstat+0x1a/0x40
[ 132.590823] [] ? vfs_read+0x10d/0x180
[ 132.590873] [] ? sys_read+0x4a/0x90
[ 132.590922] [] ? sys_poll+0x76/0x110
[ 132.590973] [] system_call_fastpath+0x16/0x1b
[ 132.591023] Code: 5d d8 4c 89 65 e0 4c 89 6d e8 4c 89 75 f0 4c 89 7d f8 66 66 66 66 90 4c 8b 27 45 31 ff 48 89 fb 41 89 f5 c6 45 cf 00 48 8b 7b 08 <8b> 07 41 89 c6 41 81 e6 00 00 07 00 75 47 80 7d cf 00 74 05 4c
[ 132.593148] RIP [] follow_managed+0x35/0x140
[ 132.593229] RSP
[ 132.593275] CR2: 000000000000005f
[ 132.593383] ---[ end trace 4828af1013d5711b ]---

System: Ubuntu 12.04 server

$ uname -a
Linux sibornal 3.2.0-29-generic #46-Ubuntu SMP Fri Jul 27 17:03:23 UTC 2012 x86_64 x86_64 x86_64 GNU/Linux

$ dpkg --status zfs-dkms
Package: zfs-dkms
Status: install ok installed
Priority: extra
Section: kernel
Installed-Size: 9707
Maintainer: Darik Horn dajhorn@vanadac.com
Architecture: amd64
Source: zfs-linux
Version: 0.6.0.71-0ubuntu1~precise1
Replaces: lzfs, lzfs-dkms
Provides: lustre-backend-fs, lzfs, lzfs-dkms
Depends: dkms (>> 2.1.1.2-5ubuntu1), spl-dkms (>= 0.6.0.71)
Conflicts: lzfs, lzfs-dkms
Description: Native ZFS filesystem kernel modules for Linux
An advanced integrated volume manager and filesystem that is designed for
performance and data integrity. Snapshots, clones, checksums, deduplication,
compression, and RAID redundancy are built-in features..
.
Includes the SPA, DMU, ZVOL, and ZPL components of ZFS.

$ dpkg --status samba
Package: samba
Status: install ok installed
Priority: optional
Section: net
Installed-Size: 22862
Maintainer: Ubuntu Developers ubuntu-devel-discuss@lists.ubuntu.com
Architecture: amd64
Version: 2:3.6.3-2ubuntu2.3
Replaces: samba-common (<= 2.0.5a-2)
Depends: samba-common (= 2:3.6.3-2ubuntu2.3), libwbclient0 (= 2:3.6.3-2ubuntu2.3), libacl1 (>= 2.2.51-5), libattr1 (>= 1:2.4.46-5), libc6 (>= 2.15), libcap2 (>= 2.10), libcomerr2 (>= 1.01), libcups2 (>= 1.4.0), libgssapi-krb5-2 (>= 1.10+dfsg~), libk5crypto3 (>= 1.6.dfsg.2), libkrb5-3 (>= 1.10+dfsg~), libldap-2.4-2 (>= 2.4.7), libpam0g (>= 0.99.7.1), libpopt0 (>= 1.14), libtalloc2 (>= 2.0.4git20101213), libtdb1 (>= 1.2.7+git20101214), zlib1g (>= 1:1.1.4), debconf (>= 0.5) | debconf-2.0, upstart-job, libpam-runtime (>= 1.0.1-11), libpam-modules, lsb-base (>= 3.2-13), procps, update-inetd, adduser, samba-common-bin
Recommends: logrotate, tdb-tools
Suggests: openbsd-inetd | inet-superserver, smbldap-tools, ldb-tools, ctdb, ufw
Conflicts: samba4 (<< 4.0.0
alpha6-2)
Conffiles:
/etc/ufw/applications.d/samba 9d474788f9a1955e16134f2794be473d
/etc/network/if-up.d/samba 2c617f0d1baebc4ba4177087a7eefc57
/etc/logrotate.d/samba 9a7687a2498ae9bfbe6c1cc252818113
/etc/cron.daily/samba f6519535df7964f95cdd7db501bf3ad2
/etc/init/smbd.conf ef97a6e85e7f13aba5e63321990a31a4
/etc/init/nmbd.conf 737e820c320801a2a0fc9e9c84d43fc0
Description: SMB/CIFS file, print, and login server for Unix
Samba is an implementation of the SMB/CIFS protocol for Unix systems,
providing support for cross-platform file and printer sharing with
Microsoft Windows, OS X, and other Unix systems. Samba can also function
as an NT4-style domain controller, and can integrate with both NT4 domains
and Active Directory realms as a member server.
.
This package provides the components necessary to use Samba as a
stand-alone file and print server. For use in an NT4 domain or Active
Directory realm, you will also need the winbind package.
.
This package is not required for connecting to existing SMB/CIFS servers
(see smbclient) or for mounting remote filesystems (see cifs-utils).
Homepage: http://www.samba.org
Original-Maintainer: Debian Samba Maintainers pkg-samba-maint@lists.alioth.debian.org

@behlendorf
Copy link
Contributor

This is a duplicate of issue #947

behlendorf pushed a commit to behlendorf/zfs that referenced this issue Oct 15, 2012
Otherwise it will cause zpl_shares_lookup() to return a invalid
pointer when an error occurs.

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
Closes openzfs#626 openzfs#885 openzfs#947 openzfs#977
unya pushed a commit to unya/zfs that referenced this issue Dec 13, 2013
Otherwise it will cause zpl_shares_lookup() to return a invalid
pointer when an error occurs.

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
Closes openzfs#626 openzfs#885 openzfs#947 openzfs#977
pcd1193182 pushed a commit to pcd1193182/zfs that referenced this issue Sep 26, 2023
Bumps [syn](https://github.com/dtolnay/syn) from 2.0.15 to 2.0.18.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](dtolnay/syn@2.0.15...2.0.18)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants