diff options
author | iedowse <iedowse@FreeBSD.org> | 2002-02-16 21:05:16 +0000 |
---|---|---|
committer | iedowse <iedowse@FreeBSD.org> | 2002-02-16 21:05:16 +0000 |
commit | febe7b98f86edabef1c4ff4db94ffe7ce4fef9fc (patch) | |
tree | 0952f18a123759d5d1883d2adade1938f7269c0e /sbin/dump/main.c | |
parent | cafeeb5d7be874d586a3728bd7361f5a495421af (diff) | |
download | FreeBSD-src-febe7b98f86edabef1c4ff4db94ffe7ce4fef9fc.zip FreeBSD-src-febe7b98f86edabef1c4ff4db94ffe7ce4fef9fc.tar.gz |
Supply progress information in dump's process title, which is useful
for monitoring automated backups. This is based on a patch by Mikhail
Teterin, with some changes to make its operation clearer and to
update the proctitle more frequently.
PR: bin/32138
Diffstat (limited to 'sbin/dump/main.c')
-rw-r--r-- | sbin/dump/main.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/sbin/dump/main.c b/sbin/dump/main.c index 392fa70..666b65f 100644 --- a/sbin/dump/main.c +++ b/sbin/dump/main.c @@ -362,9 +362,13 @@ main(argc, argv) nonodump = spcl.c_level < honorlevel; + passno = 1; + setproctitle("%s: pass 1: regular files", disk); msg("mapping (Pass I) [regular files]\n"); anydirskipped = mapfiles(maxino, &tapesize); + passno = 2; + setproctitle("%s: pass 2: directories", disk); msg("mapping (Pass II) [directories]\n"); while (anydirskipped) { anydirskipped = mapdirs(maxino, &tapesize); @@ -427,6 +431,8 @@ main(argc, argv) (void)time((time_t *)&(tstart_writing)); dumpmap(usedinomap, TS_CLRI, maxino - 1); + passno = 3; + setproctitle("%s: pass 3: directories", disk); msg("dumping (Pass III) [directories]\n"); dirty = 0; /* XXX just to get gcc to shut up */ for (map = dumpdirmap, ino = 1; ino < maxino; ino++) { @@ -445,6 +451,8 @@ main(argc, argv) (void)dumpino(dp, ino); } + passno = 4; + setproctitle("%s: pass 4: regular files", disk); msg("dumping (Pass IV) [regular files]\n"); for (map = dumpinomap, ino = 1; ino < maxino; ino++) { int mode; |