NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: port-evbmips/48564: 'tar' on evbmips-mips64el (LOONGSON) corrupts files extracted to NFS



The following reply was made to PR port-evbmips/48564; it has been noted by GNATS.

From: "John D. Baker" <jdbaker%mylinuxisp.com@localhost>
To: gnats-bugs%NetBSD.org@localhost
Cc: 
Subject: Re: port-evbmips/48564: 'tar' on evbmips-mips64el (LOONGSON) corrupts
 files extracted to NFS
Date: Fri, 17 Jul 2015 22:21:26 -0500 (CDT)

 As suggested earlier in this PR, below is the output of:
 
   $ tar cf - svcs-tst.txt | ktruss tar xf - -C /mnt/tmp | tee tar-extract-nfs.ktruss
 
 The file "svcs-tst.txt" is the first 32769 bytes (to a whole line) of
 the "/etc/services" file, just big enough to illustrate the problem.
 
 "/mnt/tmp" is an NFS-mounted filesystem and the target file is corrupted
 with alternating 8KB blocks of source file data and zero-filled regions.
 
   6130      1 ktruss   fcntl(0x4, 0x3, 0)          = 4194305, 6
   6130      1 ktruss   emul(netbsd32)
   6130      1 ktruss   netbsd32_fcntl(0x4, 0x4, 0x400001) = 0, 6
   6130      1 tar      netbsd32_execve("/usr/bin/tar", 0x7fff6cf8, 0x7fff6d10) JUSTRETURN
   6130      1 tar      emul(netbsd32)
   6130      1 tar      netbsd32_mmap(0, 0x8000, 0x3, 0x1002, 0xffffffff, 0, 0) = 0x787c8000
   6130      1 tar      netbsd32_open("/etc/ld.so.conf", 0, 0x787f4768) Err#2 ENOENT
   6130      1 tar      netbsd32_mmap(0, 0xc000, 0x3, 0x1002, 0xffffffff, 0, 0) = 0x787bc000
   6130      1 tar      netbsd32_open("/lib/libutil.so.7", 0, 0) = 3, 2021392384
   6130      1 tar      netbsd32___fstat50(0x3, 0x7fff6420) = 0, 2021392384
   6130      1 tar      netbsd32_mmap(0, 0xc000, 0x3, 0x1002, 0xffffffff, 0, 0) = 0x787b0000
   6130      1 tar      netbsd32_mmap(0, 0x4000, 0x1, 0x1, 0x3, 0, 0) = 0x787a0000
   6130      1 tar      netbsd32_munmap(0x787a0000, 0x4000) = 0, 1
   6130      1 tar      netbsd32_mmap(0, 0x2c000, 0x5, 0x10000002, 0x3, 0, 0) = 0x78780000
   6130      1 tar      netbsd32_mmap(0x787a4000, 0x4000, 0x3, 0x12, 0x3, 0, 0x14000) = 0x787a4000
   6130      1 tar      netbsd32_mmap(0x787a8000, 0x4000, 0x3, 0x1012, 0xffffffff, 0, 0) = 0x787a8000
   6130      1 tar      netbsd32_mprotect(0x78798000, 0xc000, 0) = 0, 98304
   6130      1 tar      netbsd32_close(0x3)         = 0, 52
   6130      1 tar      netbsd32_open("/lib/libgcc_s.so.1", 0, 0) = 3, 17
   6130      1 tar      netbsd32___fstat50(0x3, 0x7fff6420) = 0, 17
   6130      1 tar      netbsd32_mmap(0, 0x4000, 0x1, 0x1, 0x3, 0, 0) = 0x78770000
   6130      1 tar      netbsd32_munmap(0x78770000, 0x4000) = 0, 1
   6130      1 tar      netbsd32_mmap(0, 0x24000, 0x5, 0x10000002, 0x3, 0, 0) = 0x78750000
   6130      1 tar      netbsd32_mmap(0x78770000, 0x4000, 0x3, 0x12, 0x3, 0, 0x10000) = 0x78770000
   6130      1 tar      netbsd32_mmap(0x78774000, 0, 0x3, 0x1012, 0xffffffff, 0, 0) = 0x78774000
   6130      1 tar      netbsd32_mprotect(0x78764000, 0xc000, 0) = 0, 81920
   6130      1 tar      netbsd32_close(0x3)         = 0, 52
   6130      1 tar      netbsd32_open("/lib/libc.so.12", 0, 0) = 3, 18
   6130      1 tar      netbsd32___fstat50(0x3, 0x7fff6420) = 0, 18
   6130      1 tar      netbsd32_mmap(0, 0x4000, 0x1, 0x1, 0x3, 0, 0) = 0x78740000
   6130      1 tar      netbsd32_munmap(0x78740000, 0x4000) = 0, 1
   6130      1 tar      netbsd32_mmap(0, 0x1b8000, 0x5, 0x10000002, 0x3, 0, 0) = 0x78590000
   6130      1 tar      netbsd32_mmap(0x78700000, 0x38000, 0x3, 0x12, 0x3, 0, 0x160000) = 0x78700000
   6130      1 tar      netbsd32_mmap(0x78738000, 0x10000, 0x3, 0x1012, 0xffffffff, 0, 0) = 0x78738000
   6130      1 tar      netbsd32_mprotect(0x786f4000, 0xc000, 0) = 0, 1458176
   6130      1 tar      netbsd32_close(0x3)         = 0, 52
   6130      1 tar      netbsd32_mmap(0, 0xc000, 0x3, 0x1002, 0xffffffff, 0, 0) = 0x78774000
   6130      1 tar      netbsd32__lwp_setprivate(0x78783008) = 0, 1
   6130      1 tar      _lwp_self()                 = 1, 2021392384
   6130      1 tar      netbsd32___sigprocmask14(0x1, 0x7fff6be0, 0x7fff6c50) = 0, -1
   6130      1 tar      netbsd32___sigprocmask14(0x3, 0x7fff6c50, 0) = 0, 2021442208
   6130      1 tar      netbsd32___sysctl(0x786dcec0, 0x2, 0x7873b990, 0x7fff6b60, 0, 0) = 0, 1
   6130      1 tar      _lwp_self()                 = 1, -1
   6130      1 tar      netbsd32___sigprocmask14(0x1, 0x7fff6b70, 0x7fff6c50) = 0, -1
   6130      1 tar      netbsd32___sigprocmask14(0x3, 0x7fff6c50, 0) = 0, 2021588992
   6130      1 tar      _lwp_self()                 = 1, 2020828392
   6130      1 tar      netbsd32___sigprocmask14(0x1, 0x7fff6b70, 0x7fff6c50) = 0, -1
   6130      1 tar      netbsd32___sigprocmask14(0x3, 0x7fff6c50, 0) = 0, 2021588992
   6130      1 tar      _lwp_self()                 = 1, 2021072312
   6130      1 tar      netbsd32___sigprocmask14(0x1, 0x7fff6b70, 0x7fff6c50) = 0, -1
   6130      1 tar      netbsd32___sigprocmask14(0x3, 0x7fff6c50, 0) = 0, 2021442204
   6130      1 tar      netbsd32_getrlimit(0x2, 0x7fff6c90) = 0, 7
   6130      1 tar      netbsd32_setrlimit(0x2, 0x7fff6c90) = 0, 7
   6130      1 tar      netbsd32_getrlimit(0x1, 0x7fff6c90) = 0, 7
   6130      1 tar      netbsd32_setrlimit(0x1, 0x7fff6c90) = 0, 7
   6130      1 tar      netbsd32_getrlimit(0x3, 0x7fff6c90) = 0, 7
   6130      1 tar      netbsd32_setrlimit(0x3, 0x7fff6c90) = 0, 7
   6130      1 tar      netbsd32_getrlimit(0x5, 0x7fff6c90) = 0, 7
   6130      1 tar      netbsd32_setrlimit(0x5, 0x7fff6c90) = 0, 7
   6130      1 tar      netbsd32___sigaction_sigtramp(0x1, 0x7fff6c78, 0x7fff6c60, 0x7863d040, 0x2) = 0, 2020855024
   6130      1 tar      netbsd32___sigaction_sigtramp(0xf, 0x7fff6c78, 0x7fff6c60, 0x7863d040, 0x2) = 0, 2020855024
   6130      1 tar      netbsd32___sigaction_sigtramp(0x2, 0x7fff6c78, 0x7fff6c60, 0x7863d040, 0x2) = 0, 2020855024
   6130      1 tar      netbsd32___sigaction_sigtramp(0x3, 0x7fff6c78, 0x7fff6c60, 0x7863d040, 0x2) = 0, 2020855024
   6130      1 tar      netbsd32___sigaction_sigtramp(0x18, 0x7fff6c78, 0x7fff6c60, 0x7863d040, 0x2) = 0, 2020855024
   6130      1 tar      netbsd32___sigaction_sigtramp(0xd, 0x7fff6c78, 0x7fff6c60, 0x7863d040, 0x2) = 0, 2020855024
   6130      1 tar      netbsd32___sigaction_sigtramp(0x19, 0x7fff6c78, 0x7fff6c60, 0x7863d040, 0x2) = 0, 2020855024
   6130      1 tar      netbsd32_open("/dev/tty", 0x2, 0x7fff6c60) = 3, 2020855024
   6130      1 tar      netbsd32_fcntl(0x3, 0x3, 0) = 2
   6130      1 tar      netbsd32_fcntl(0x3, 0x3, 0) = 2
   6130      1 tar      netbsd32_open(".", 0, 0)    = 4, 268697600
   6130      1 tar      netbsd32___getcwd(0x10037678, 0x400) = 23, 7
   6130      1 tar      netbsd32___sysctl(0x7fff6790, 0x2, 0x7873ef00, 0x7fff6b98, 0, 0) = 0, 6
   6130      1 tar      netbsd32___sysctl(0x7fff66f0, 0x2, 0x78747240, 0x7fff66f8, 0, 0) = 0, 6
   6130      1 tar      netbsd32_readlink("/etc/malloc.conf", 0x7fff6790, 0x400) Err#2 ENOENT
   6130      1 tar      netbsd32_break(0x10045e10)  = 0, 16384
   6130      1 tar      netbsd32_break(0x10045e10)  = 0, -1
   6130      1 tar      netbsd32_break(0x10100000)  = 0, -1
   6130      1 tar      netbsd32_mmap(0, 0x100000, 0x3, 0x14001002, 0xffffffff, 0, 0) = 0x78400000
   6130      1 tar      netbsd32___gettimeofday50(0x7fff6c30, 0) = 0, 7
   6130      1 tar      netbsd32___sigaction_sigtramp(0x1d, 0x7fff6c28, 0x7fff6c10, 0x7863d040, 0x2) = 0, 2020855024
   6130      1 tar      netbsd32_chdir("/mnt/tmp")  = 0, 7
   6130      1 tar      netbsd32___getcwd(0x10037678, 0x400) = 9, -1
   6130      1 tar      netbsd32___fstat50(0, 0x100375c0) = 0, -1
   6130      1 tar      netbsd32_lseek(0, 0, 0, 0x1) Err#29 ESPIPE
   6130      1 tar      netbsd32_read(0, 0x10037e90, 0x7e00) = 16384, 7
        "svcs-tst.txt\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
   6130      1 tar      netbsd32___gettimeofday50(0x7fff6b10, 0) = 0, 1954051118
   6130      1 tar      netbsd32___stat50("/etc/nsswitch.conf", 0x7fff6820) = 0, 1
   6130      1 tar      netbsd32_open("/etc/nsswitch.conf", 0x400000, 0x1b6) = 5, 2020865136
   6130      1 tar      netbsd32___fstat50(0x5, 0x7fff6580) = 0, 2020870496
   6130      1 tar      netbsd32_read(0x5, 0x78420000, 0x4000) = 621, 1
        "#\t$NetBSD: nsswitch.conf,v 1.6 2009/10/25 00:17:06 tsarna Exp $\n#\n"
   6130      1 tar      netbsd32_read(0x5, 0x78420000, 0x4000) = 0, 2020870496
        ""
   6130      1 tar      _lwp_self()                 = 1, 2147443439
   6130      1 tar      netbsd32___sigprocmask14(0x1, 0x7fff6210, 0x7fff6280) = 0, -1
   6130      1 tar      netbsd32_open("/lib/nss_compat.so.0", 0, 0) Err#2 ENOENT
   6130      1 tar      netbsd32_open("/usr/lib/nss_compat.so.0", 0, 0) Err#2 ENOENT
   6130      1 tar      netbsd32___sigprocmask14(0x3, 0x7fff6280, 0) = 0
   6130      1 tar      _lwp_self()                 = 1, 2147443436
   6130      1 tar      netbsd32___sigprocmask14(0x1, 0x7fff6210, 0x7fff6280) = 0, -1
   6130      1 tar      netbsd32_open("/lib/nss_nis.so.0", 0, 0) Err#2 ENOENT
   6130      1 tar      netbsd32_open("/usr/lib/nss_nis.so.0", 0, 0) Err#2 ENOENT
   6130      1 tar      netbsd32___sigprocmask14(0x3, 0x7fff6280, 0) = 0
   6130      1 tar      _lwp_self()                 = 1, 2147443438
   6130      1 tar      netbsd32___sigprocmask14(0x1, 0x7fff6210, 0x7fff6280) = 0, -1
   6130      1 tar      netbsd32_open("/lib/nss_files.so.0", 0, 0) Err#2 ENOENT
   6130      1 tar      netbsd32_open("/usr/lib/nss_files.so.0", 0, 0) Err#2 ENOENT
   6130      1 tar      netbsd32___sigprocmask14(0x3, 0x7fff6280, 0) = 0
   6130      1 tar      _lwp_self()                 = 1, 2147443436
   6130      1 tar      netbsd32___sigprocmask14(0x1, 0x7fff6210, 0x7fff6280) = 0, -1
   6130      1 tar      netbsd32_open("/lib/nss_dns.so.0", 0, 0) Err#2 ENOENT
   6130      1 tar      netbsd32_open("/usr/lib/nss_dns.so.0", 0, 0) Err#2 ENOENT
   6130      1 tar      netbsd32___sigprocmask14(0x3, 0x7fff6280, 0) = 0
   6130      1 tar      netbsd32_close(0x5)         = 0, 2020864856
   6130      1 tar      netbsd32___sysctl(0x7fff6790, 0x2, 0x787474e0, 0x7fff6798, 0, 0) = 0, 1
   6130      1 tar      netbsd32_open("/etc/group", 0x400000, 0x1b6) = 5, 2020865136
   6130      1 tar      netbsd32___stat50("/etc/nsswitch.conf", 0x7fff6820) = 0, 1
   6130      1 tar      netbsd32___fstat50(0x5, 0x7fff66a0) = 0, 2020855024
   6130      1 tar      netbsd32_lseek(0x5, 0, 0, 0x1) = 0, -1113715064
   6130      1 tar      netbsd32_lseek(0x5, 0, 0, 0) = 0, -1113714824
   6130      1 tar      netbsd32_read(0x5, 0x78420000, 0x4000) = 701, 2020870496
        "wheel:*:0:root,sysop\ndaemon:*:1:daemon\nkmem:*:2:root\nsys:*:3:root"
   6130      1 tar      netbsd32___stat50("/etc/nsswitch.conf", 0x7fff6820) = 0, 1
   6130      1 tar      netbsd32___sysctl(0x7fff6770, 0x2, 0x787474e0, 0x7fff6778, 0, 0) = 0, 1
   6130      1 tar      geteuid()                   = 289
   6130      1 tar      geteuid()                   = 289
   6130      1 tar      netbsd32___stat50("/etc/pwd.db", 0x7fff6718) = 0, 2017690140
   6130      1 tar      netbsd32_open("/etc/pwd.db", 0x400000, 0) = 6, 2017690140
   6130      1 tar      netbsd32___fstat50(0x6, 0x7fff6718) = 0, 2017690140
   6130      1 tar      netbsd32_read(0x6, 0x78438040, 0x104) = 260, 2020385648
        "\0\^F\^Ua\0\0\0\^B\0\0\^D\M-R\0\0\^P\0\0\0\0\f\0\0\^A\0\0\0\^A\0\0\0"
   6130      1 tar      netbsd32_pread(0x6, 0x7843d000, 0x1000, 0, 0x7000) = 4096, 2020855024
        ""\0\M-x\^O\M-t\^O\M-o\^O\M^\\^O\M^W\^OG\^OA\^O\M-u\^N\M-m\^N\M^W\^N"
   6130      1 tar      netbsd32_pread(0x6, 0x7843e000, 0x1000, 0, 0x1000) = 4096, 2020855024
        "\^N\0\M-{\^O\M-/\^O\M-*\^OZ\^OU\^O\^E\^O\0\^O\M-/\^N\M-*\^NT\^NO\^N"
   6130      1 tar      netbsd32_pread(0x6, 0x7843f000, 0x1000, 0, 0x5000) = 4096, 2020855024
        "\^Z\0\M-{\^O\M-2\^O\M--\^Oe\^O`\^O\^O\^O\a\^O\M-1\^N\M-*\^N^\^NW\^N\f"
   6130      1 tar      netbsd32___stat50("/etc/nsswitch.conf", 0x7fff6820) = 0, 1
   6130      1 tar      netbsd32_pread(0x6, 0x78440000, 0x1000, 0, 0x8000) = 4096, 2020855024
        "\^X\0\M-{\^O\M-+\^O\M-&\^OP\^OK\^O\M-z\^N\M-u\^N\M-%\^N\240\^NW\^NR"
   6130      1 tar      netbsd32_mmap(0, 0x4000, 0x3, 0x1002, 0xffffffff, 0, 0) = 0x787ac000
   6130      1 tar      netbsd32_minherit(0x787ac000, 0x4000, 0x4) = 0, 2020855024
   6130      1 tar      netbsd32___sysctl(0x7fff6458, 0x2, 0x7fff6438, 0x7fff6460, 0, 0) = 0, 1
   6130      1 tar      netbsd32_open("svcs-tst.txt.OMgHxX", 0xa02, 0x180) = 7, 2147445152
   6130      1 tar      netbsd32___fstat50(0x7, 0x7fff6a30) = 0, -1
   6130      1 tar      netbsd32_write(0x7, 0x10038090, 0x2000) = 8192, 7
        "# $NetBSD: services,v 1.98 2014/07/22 17:11:09 wiz Exp $\n# See also:"
   6130      1 tar      netbsd32_write(0x7, 0x1003a090, 0x1e00) = 7680, 512
        "           Defined TXT keys: u=<username> p=<password> path=<path>\nf"
   6130      1 tar      netbsd32_read(0, 0x10037e90, 0x7e00) = 16384, 5
        "   [Susie_Armstrong]                                  [Susie_Armstron"
   6130      1 tar      netbsd32_write(0x7, 0x10037e90, 0x200) = 512
        "   [Susie_Armstrong]                                  [Susie_Armstron"
   6130      1 tar      netbsd32_write(0x7, 0x10038090, 0x2000) = 8192
        "e            [Susie_Armstrong]                                  [Susi"
   6130      1 tar      netbsd32_write(0x7, 0x1003a090, 0x1e00) = 7680, 512
        "                                                                     "
   6130      1 tar      netbsd32_read(0, 0x10037e90, 0x7e00) = 8192, 5
        "                                                                     "
   6130      1 tar      netbsd32_write(0x7, 0x10037e90, 0x200) = 512
        "                                                                     "
   6130      1 tar      netbsd32_write(0x7, 0x10038090, 0x1) = 1, 8191
        "\n"
   6130      1 tar      netbsd32_close(0x7)         = 0
   6130      1 tar      netbsd32_umask(0)           = 18, 7
   6130      1 tar      netbsd32_umask(0x12)        = 0, 7
   6130      1 tar      netbsd32_lchmod("svcs-tst.txt.OMgHxX", 0x1a4) = 0, 7
   6130      1 tar      netbsd32___lutimes50("svcs-tst.txt.OMgHxX", 0x7fff6aa8) = 0, 7
   6130      1 tar      netbsd32_rename("svcs-tst.txt.OMgHxX", "svcs-tst.txt") = 0, 7
   6130      1 tar      netbsd32_read(0, 0x7ffeeca0, 0x7e00) = 0, 4
        ""
   6130      1 tar      netbsd32___sigprocmask14(0x1, 0x10045e00, 0) = 0, 7
   6130      1 tar      netbsd32_close(0)           = 0, 5
   6130      1 tar      _lwp_self()                 = 1, 2020893816
   6130      1 tar      netbsd32___sigprocmask14(0x1, 0x7fff6b60, 0x7fff6bd0) = 0, -1
   6130      1 tar      netbsd32___sigprocmask14(0x3, 0x7fff6bd0, 0) = 0, 2021588992
   6130      1 tar      _lwp_self()                 = 1, 2021064704
   6130      1 tar      netbsd32___sigprocmask14(0x1, 0x7fff6b60, 0x7fff6bd0) = 0, -1
   6130      1 tar      netbsd32___sigprocmask14(0x3, 0x7fff6bd0, 0) = 0, 2021588992
   6130      1 tar      _lwp_self()                 = 1, 2021064704
   6130      1 tar      netbsd32___sigprocmask14(0x1, 0x7fff6b60, 0x7fff6bd0) = 0, -1
   6130      1 tar      netbsd32___sigprocmask14(0x3, 0x7fff6bd0, 0) = 0, 2021588992
   6130      1 tar      _lwp_self()                 = 1, 2021064704
   6130      1 tar      netbsd32___sigprocmask14(0x1, 0x7fff6b60, 0x7fff6bd0) = 0, -1
   6130      1 tar      netbsd32___sigprocmask14(0x3, 0x7fff6bd0, 0) = 0, 2021442460
   6130      1 tar      netbsd32_exit(0)
 
 -- 
 |/"\ John D. Baker, KN5UKS               NetBSD     Darwin/MacOS X
 |\ / jdbaker[snail]mylinuxisp[flyspeck]com    OpenBSD            FreeBSD
 | X  No HTML/proprietary data in email.   BSD just sits there and works!
 |/ \ GPGkeyID:  D703 4A7E 479F 63F8 D3F4  BD99 9572 8F23 E4AD 1645
 


Home | Main Index | Thread Index | Old Index