search for: st_rdev

Displaying 20 results from an estimated 283 matches for "st_rdev".

Did you mean: st_dev
2008 Sep 15
0
Trace log of unify when glusterfs freezes
...ocol_xfer] brick-ns: attempting to pipeline request type(1) op(34) with handshake 2008-09-15 20:16:53 T [trace.c:535:trace_lookup_cbk] trace: callid: 2 (*this=0x50cd30, op_ret=0, op_errno=2, inode=0x5266a0, *buf=0x526ab0 {st_dev=2049, st_ino=1242079, st_mode=16877, st_nlink=13, st_uid=0, st_gid=0, st_rdev=0, st_size=4096, st_blksize=4096, st_blocks=16}) 2008-09-15 20:16:55 T [trace.c:1117:trace_lookup] trace: callid: 3 (*this=0x50cd30, loc=0x526768 {path=/, inode=0x5266a0} ) 2008-09-15 20:16:55 T [trace.c:535:trace_lookup_cbk] trace: callid: 3 (*this=0x50cd30, op_ret=0, op_errno=2, inode=0x5266a0,...
2013 Jul 09
2
[PATCH 2/2] LXC: hostdev: parent directroy for hostdev atomically
...for device %s"), + dev); goto cleanup; } mode = 0700 | S_IFBLK; - VIR_DEBUG("Creating dev %s (%d,%d)", - def->source.caps.u.storage.block, + VIR_DEBUG("Creating dev %s (%d,%d)", dev, major(sb.st_rdev), minor(sb.st_rdev)); - if (mknod(def->source.caps.u.storage.block, mode, sb.st_rdev) < 0) { + if (mknod(dev, mode, sb.st_rdev) < 0) { virReportSystemError(errno, _("Unable to create device %s"), - def->s...
2006 Apr 16
2
e2fsck dies with signal 11
Hi I got a strange error, happening on two of my ext3 partitions. What can be wrong? And why does e2fsck error out, instead of displaying an error message? Best regards keld fsck /dev/hda6 fsck 1.38 (30-Jun-2005) e2fsck 1.38 (30-Jun-2005) Warning... fsck.ext3 for device /dev/hda6 exited with signal 11. also From my dmesg: <1>general protection fault: e7a8 [#3] Modules linked in:
2016 Jan 06
0
[klibc:master] ppc64: fix struct stat
....net> AuthorDate: Wed, 6 Jan 2016 00:44:16 +0000 Committer: H. Peter Anvin <hpa at linux.intel.com> CommitDate: Tue, 5 Jan 2016 17:45:55 -0800 [klibc] ppc64: fix struct stat On ppc64 the struct stat defined by klibc matches the kernel one. However it contains implicit padding before the st_rdev field due to the 64-bit alignement. For internal reasons, klibc defines st_rdev as a pair of 32-bit values (using the __stdev64 macro). They only need to be 32-bit aligned and as a consequence st->st_rdev is incorrectly defined. The solution is to add an explicit padding in the structure. This...
2013 Jul 08
4
Re: Permission problem with /dev/net/tun
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hi Daniel, On 07/08/2013 11:41 AM, Daniel P. Berrange wrote: >> the symptom my libvirt LXC container suffers from is: >> root@depot:/dev/net# ls -la total 0 drwxr-xr-x 2 root root 40 >> Jun 29 16:26 . drwxr-xr-x 5 root root 480 Jun 29 16:26 .. >> root@depot:/dev/net# mknod tun c 10 200 mknod: `tun': Operation >>
2012 Sep 05
3
BTRFS thinks device is busy [kernel 3.5.3]
Hi, I''m running OpenSuse 12.2 with kernel 3.5.3 HBA= LSI 1068e using the MPTSAS driver (patched) (https://patchwork.kernel.org/patch/1379181/) SANOS1:/media # uname -a Linux SANOS1 3.5.3 #3 SMP Sun Sep 2 18:44:37 CEST 2012 x86_64 x86_64 x86_64 GNU/Linux I''ve tried to simulate a disk replacement but it seems that now /dev/sdg is stuck in the btrfs pool (RAID10) SANOS1:/media #
2011 Jul 07
5
[PATCH 0/5] checkpatch cleanups
It seems checkpatch errors krept in, this is a first go. Next run will go into usr/kinit directory. No code changes, just codingstyle fixes (verified with size(3)). maximilian attems (5): [klibc] sleep: have argument on next line [klibc] readklink: remove unneeded braces [klibc] mount: whitespace policy [klibc] ls: fix various checkpatch complaints [klibc] tests: checkpatch fixlets
2010 Dec 21
4
tap2:remus:backup_ip:9000|aio:/path_to_disk.img not working - OSError: [Errno 2] No such file or directory
...tloader() File "usr/lib/python2.5/site-packages/xen/xend/XendDomainInfo.py", line 3245, in _configureBootloader mounted = devtype in [''tap'', ''tap2''] and taptype != ''aio'' and taptype != ''sync'' and not os.stat(fn).st_rdev OSError: [Errno 2] No such file or directory: ''backup_ip:9000|aio:/home/xen/domains/lucid/disk.img'' [2010-12-21 00:32:23 2091] DEBUG (XendDomainInfo:3053) XendDomainInfo.destroy: domid=5 [2010-12-21 00:32:23 2091] DEBUG (XendDomainInfo:2416) No device model [2010-12-21 00:32:23 20...
2008 Jul 03
1
extlinux and install script
...b = setmntent("/proc/mounts", "r")) ) { while ( (mnt = getmntent(mtab)) ) { if ( (!strcmp(mnt->mnt_type, "ext2") || !strcmp(mnt->mnt_type, "ext3")) && !stat(mnt->mnt_fsname, &dst) && dst.st_rdev == st.st_dev ) { devname = mnt->mnt_fsname; break; } } } if ( !devname ) { /* Didn't find it in /proc/mounts, try /etc/mtab */ if ( (mtab = setmntent("/etc/mtab", "r")) ) { while ( (mnt = getmntent(mtab)) ) { devname =...
2011 Jul 16
1
crash in extlinux/main
Hi, I found a bug in extlinux/main.c. Writing a bootloader on a file mounted via /dev/mapper in Lunix it crashed on me with a segment fault. The bug is here: if (!ioctl(devfd, HDIO_GETGEO, &geo)) { Since we are already called with geo as a pointer the & is wrong as the pointer itself will be overwritten. This works: int get_geometry(int devfd, uint64_t totalbytes, struct
2009 May 29
1
[PATCH v2] klibc-utils: add simple ls
...uintmax_t) st->st_uid)) > max_uid) + max_uid = bytes; + + if ((bytes = snprintf(NULL, 0, "%ju", (uintmax_t) st->st_gid)) > max_gid) + max_gid = bytes; + + if (S_ISCHR(st->st_mode) || S_ISBLK(st->st_mode)) { + if ((bytes = snprintf(NULL, 0, "%u", major(st->st_rdev))) > max_maj) + max_maj = bytes; + + if ((bytes = snprintf(NULL, 0, "%u", minor(st->st_rdev))) > max_min) + max_min = bytes; + + max_size = max_maj + max_min + 1; + } + else { + if ((bytes = snprintf(NULL, 0, "%ju", (uintmax_t) st->st_size)) > max_size) +...
2009 May 28
1
[PATCH] klibc-utils: add minils
...uintmax_t) st->st_uid)) > max_uid) + max_uid = bytes; + + if ((bytes = snprintf(NULL, 0, "%ju", (uintmax_t) st->st_gid)) > max_gid) + max_gid = bytes; + + if (S_ISCHR(st->st_mode) || S_ISBLK(st->st_mode)) { + if ((bytes = snprintf(NULL, 0, "%u", major(st->st_rdev))) > max_maj) + max_maj = bytes; + + if ((bytes = snprintf(NULL, 0, "%u", minor(st->st_rdev))) > max_min) + max_min = bytes; + + max_size = max_maj + max_min + 1; + } + else { + if ((bytes = snprintf(NULL, 0, "%ju", (uintmax_t) st->st_size)) > max_size) +...
2009 Nov 14
2
[PATCH] btrfs-progs: Check mount status of multidevice filesystems
...lude "radix-tree.h" #include "ctree.h" @@ -586,46 +588,105 @@ error: return ret; } +int is_loop_device (const char *device) { + struct stat statbuf; + + if(stat(device, &statbuf) < 0) + return -errno; + + return (S_ISBLK(statbuf.st_mode) && + major(statbuf.st_rdev) == LOOP_MAJOR); +} + +int is_same_blk_file(const char* a, const char* b) +{ + struct stat st_buf_a, st_buf_b; + char real_a[PATH_MAX]; + char real_b[PATH_MAX]; + + if(!realpath(a, real_a) || + !realpath(b, real_b)) + { + return -errno; + } + + /* Identical path? */ + if(strcmp(real_a, real_b)...
2014 Sep 22
2
[PATCH] New APIs: Implement stat calls that return nanosecond timestamps (RHBZ#1144891).
...ev); - output_int64 (stat->ino); - output_int64 (stat->nlink); - output_int64_dev (stat->rdev); - output_int64 (stat->blocks); + output_int64_dev (stat->st_dev); + output_int64 (stat->st_ino); + output_int64 (stat->st_nlink); + output_int64_dev (stat->st_rdev); + output_int64 (stat->st_blocks); } /* Disabled for now -- user would definitely want these to be interpreted. @@ -524,7 +524,7 @@ show_file (const char *dir, const char *name, path = full_path (dir, name); - if (checksum && is_reg (stat->mode)) { + if (checksum...
2018 Apr 10
0
[PATCH v2 3/5] daemon: move Lvm.lv_canonical to new Lvm_utils module
...- * - * Note use of 'stat' instead of 'lstat' so that symlinks are fully - * resolved. - *) -let lv_canonical device = - let stat1 = stat device in - let lvs = lvs () in - try - Some ( - List.find ( - fun lv -> - let stat2 = stat lv in - stat1.st_rdev = stat2.st_rdev - ) lvs - ) - with - | Not_found -> None diff --git a/daemon/lvm.mli b/daemon/lvm.mli index e9a6faeca..592168433 100644 --- a/daemon/lvm.mli +++ b/daemon/lvm.mli @@ -17,13 +17,3 @@ *) val lvs : unit -> string list - -val lv_canonical : string -> string option...
2015 Jan 02
2
(no subject)
Hi, we needed these changes when we had to build a guest image compatible with a starting guest image but not backed by it in any way? We needed some tool to check our progress, comparing original and? rebuilt (from scratch) images, and virt-diff seemed the best option, but? we had to soften the comparison to reduce the noise in the output. I added some options to ignore certain informations when
2005 May 16
2
Assertion Failure in mbox-sync.c
...bffffa44, envp=0xbffffa4c) at main.c:228 I'm not sure about the variables here, the core file's still here if any other info will help: (gdb) p sync_ctx->input->real_stream->statbuf $5 = {st_dev = 0, __pad1 = 0, __st_ino = 0, st_mode = 0, st_nlink = 0, st_uid = 0, st_gid = 0, st_rdev = 0, __pad2 = 0, st_size = 4294967295, st_blksize = 0, st_blocks = 0, st_atim = {tv_sec = 1116279667, tv_nsec = 0}, st_mtim = {tv_sec = 1116279667, tv_nsec = 0}, st_ctim = { tv_sec = 1116279667, tv_nsec = 0}, st_ino = 0} (gdb) p sync_ctx->file_input->v_offset $8 = 142294527 The mb...
2004 Sep 05
4
Asterisk & sudo from httpd
...= 0 socket(PF_FILE, SOCK_STREAM, 0) = 3 connect(3, {sa_family=AF_FILE, path="/var/run/asterisk.ctl"}, 110) = -1 EACCES (Permission denied) close(3) = 0 time([1094419366]) = 1094419366 fstat64(1, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 0), ...}) = 0 mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xbf334000 write(1, "Unable to connect to remote aste"..., 37) = 37 munmap(0xbf334000, 4096) = 0 exit_group(1) = ? ------------------------------...
2013 Feb 12
10
[PATCH] Btrfs-progs: check out if the swap device
...0 on error or 0 if not the swap device. + */ +int is_swap_device(const char *file) +{ + FILE *f; + struct stat st_buf; + char buf[1024]; + char *cp; + dev_t rdev; + int ret = 0; + + if (stat(file, &st_buf) < 0) + return -errno; + if (!S_ISBLK(st_buf.st_mode)) + return 0; + + rdev = st_buf.st_rdev; + + if ((f = fopen("/proc/swaps", "r")) == NULL) + return -errno; + + /* skip the first line */ + if (fgets(buf, sizeof(buf), f) == NULL) + goto out; + + while (fgets(buf, sizeof(buf), f) != NULL) { + if ((cp = strchr(buf, '' '')) != NULL) + *cp = 0; + if...
2015 Jan 02
0
[PATCH] virt-diff: add additional ignore options
...tat_copy = guestfs_copy_statns (stat_orig); if (stat == NULL) { perror ("guestfs_copy_stat"); goto error; } + if (no_compare_perms) + stat->st_mode &= 0170000; + + if (no_compare_extra_stats) + stat->st_dev = stat->st_ino = stat->st_nlink = stat->st_rdev = + stat->st_blocks = 0; + + if (no_compare_uids) + stat->st_uid = stat->st_gid = 0; + + if (no_compare_times) + stat->st_atime_sec = stat->st_mtime_sec = stat->st_ctime_sec = + stat->st_atime_nsec = stat->st_mtime_nsec = stat->st_ctime_nsec = 0; + xa...