This is a discussion on fssnap: ioctl: error 16: Device busy within the comp.unix.solaris forums, part of the Solaris Operating System category; --> Hello. On a Solaris 9 machine, I'm trying to create a UFS snapshot of my /var, /usr and /opt ...
| |||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| Hello. On a Solaris 9 machine, I'm trying to create a UFS snapshot of my /var, /usr and /opt filesystems. They all fail like this: # fssnap -F ufs -o backing-store=/.backup/backing-stores/opt /opt fssnap: ioctl: error 16: Device busy Why do I get that error message? What's so busy, that a snapshot cannot be created? I read somewhere, that a running NTP daemon might cause this problem - but there's no NTPd running on that box. $ ps -ef | grep -v grep | grep ntp $ I can create snapshots of other filesystems just fine: $ fssnap -i 0 /export/home 1 /var/store 2 /u02 3 /u03 4 /u01 5 / What's stopping me from creating snapshots of /opt, /usr and/or /var? Thanks, Michael |
| |||
| In <1650836.FqbS0PLNBR@michael-schmarck.my-fqdn.de> Michael Schmarck <michael.schmarck@here.la> writes: >On a Solaris 9 machine, I'm trying to create a UFS snapshot of my >/var, /usr and /opt filesystems. They all fail like this: > # fssnap -F ufs -o backing-store=/.backup/backing-stores/opt /opt > fssnap: ioctl: error 16: Device busy >I read somewhere, that a running NTP daemon might cause this >problem - but there's no NTPd running on that box. The man page for fssnap_ufs mentions other conditions that might prevent snapshots being taken. Look at the very end of the man page. -- -Gary Mills- -Unix Support- -U of M Academic Computing and Networking- |
| |||
| Michael Schmarck <michael.schmarck@here.la> wrote: > Hello. > > On a Solaris 9 machine, I'm trying to create a UFS snapshot of my > /var, /usr and /opt filesystems. They all fail like this: > > # fssnap -F ufs -o backing-store=/.backup/backing-stores/opt /opt > fssnap: ioctl: error 16: Device busy > > Why do I get that error message? What's so busy, that a snapshot > cannot be created? fssnap locks the filesystem before the snapshot. If the lock fails, so does the snap. > I read somewhere, that a running NTP daemon might cause this > problem - but there's no NTPd running on that box. > > $ ps -ef | grep -v grep | grep ntp > $ NTP causes this issue because it normally runs in the realtime scheduling class. And you can't lock devices that an RT process has open. What do you get for this output? $ ps -e -o 'pid,class,args' | grep ' RT ' 304 RT /usr/lib/inet/xntpd 3073 TS grep RT You may not have NTP running, but perhaps some other RT class is. -- Darren Dunham ddunham@taos.com Senior Technical Consultant TAOS http://www.taos.com/ Got some Dr Pepper? San Francisco, CA bay area < This line left intentionally blank to confuse you. > |
| |||
| ddunham@taos.com (Darren Dunham) writes: >NTP causes this issue because it normally runs in the realtime >scheduling class. And you can't lock devices that an RT process has >open. What do you get for this output? I think it's actually the memory locking it does, not the RT class. Casper -- Expressed in this posting are my opinions. They are in no way related to opinions held by my employer, Sun Microsystems. Statements on Sun products included here are not gospel and may be fiction rather than truth. |
| |||
| Casper H.S. Dik <Casper.Dik@sun.com> wrote: > ddunham@taos.com (Darren Dunham) writes: > >>NTP causes this issue because it normally runs in the realtime >>scheduling class. And you can't lock devices that an RT process has >>open. What do you get for this output? > > I think it's actually the memory locking it does, not the RT class. Darn. I was sure I'd personally tried this a long time ago. Sure enough, I cannot get any other RT process to prevent the lock from succeeding. I wonder what I tested the first time... -- Darren Dunham ddunham@taos.com Senior Technical Consultant TAOS http://www.taos.com/ Got some Dr Pepper? San Francisco, CA bay area < This line left intentionally blank to confuse you. > |
| |||
| Gary Mills <mills@cc.umanitoba.ca> wrote: > The man page for fssnap_ufs mentions other conditions that might > prevent snapshots being taken. Look at the very end of the man page. I'm not seeing something there. Where should that be? Under NOTES? There, I've got: NOTES The fssnap device files should be treated like a regular disk block or character device. The association between a file system and the snapshot is lost when the snapshot is deleted or the system reboots. Snapshot persistence across reboots is not currently sup- ported. To avoid unnecessary performance impacts, perform the snapshot and system backup when the system is least active. SunOS 5.9 Last change: 3 Jun 2002 6 Are you sure that the man page mentions something? If so, could you please be so kind and paste the relevant section? Thanks a lot, Michael |
| |||
| Gary Mills <mills@cc.umanitoba.ca> wrote: > The man page for fssnap_ufs mentions other conditions that might > prevent snapshots being taken. Look at the very end of the man page. I'm not seeing something there. Where should that be? Under NOTES? [...] It would have been nice, if you would've mentioned, that there's nothing in the S9 man pages and that you're refering to the Solaris 10 man pages Anyway, found something there now. It is not possible to perform a snapshot of a file system if any of the following conditions are true: o The file system is in use by system accounting o The file system contains a local swap file o The file system is used as backing store by an application that uses mlock(3C) to lock its pages. Typically, these are real time applications, such as xntpd(1M). These conditions result in fssnap being unable to write lock the file system prior to performing the snapshot. How do I check, if the filesystems are in use by system accounting? $ swap -l swapfile dev swaplo blocks free /dev/md/dsk/d1 85,1 16 4194800 4194800 /dev/dsk/c3t0d0s1 32,249 16 2105136 2105136 Ie. there's no local swap file on any of those filesystems. How do I check if an application uses mlock to lock its pages? Thanks a lot, Michael |
| |||
| Darren Dunham <ddunham@taos.com> wrote: > Michael Schmarck <michael.schmarck@here.la> wrote: >> Hello. >> >> On a Solaris 9 machine, I'm trying to create a UFS snapshot of my >> /var, /usr and /opt filesystems. They all fail like this: >> >> # fssnap -F ufs -o backing-store=/.backup/backing-stores/opt /opt >> fssnap: ioctl: error 16: Device busy >> >> Why do I get that error message? What's so busy, that a snapshot >> cannot be created? > > fssnap locks the filesystem before the snapshot. If the lock fails, so > does the snap. Thanks. Why does the lock fail? application does mlock. How do I find out which application this is? > NTP causes this issue because it normally runs in the realtime > scheduling class. And you can't lock devices that an RT process has > open. What do you get for this output? > > $ ps -e -o 'pid,class,args' | grep ' RT ' > 304 RT /usr/lib/inet/xntpd > 3073 TS grep RT $ ps -e -o 'pid,class,args' | grep ' RT ' 1683 TS /opt/csw/bin/ggrep --colour=auto RT # fssnap -F ufs -o backing-store=${bs_name} $dir fssnap: ioctl: error 16: Device busy > You may not have NTP running, but perhaps some other RT class is. No. Michael |
| ||||
| On Feb 26, 10:07 pm, Michael Schmarck <michael.schma...@here.la> wrote: > > fssnap locks the filesystem before the snapshot. If the lock fails, so > > does the snap. > > Thanks. Why does the lock fail? > application does mlock. How do I find out which application this is? Michael, It won't be fun but you can use pmap -x pid Try as root (not well tested...): for pid in $(pgrep "") do pmap -x ${pid} 2>/dev/null | nawk '$1 == "total" exit $6}' || echo ${pid} done --Brett Monroe |
| Thread Tools | |
| Display Modes | |
|
|