summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2006-03-22Tighten up profile parsing code by combining functionsTheodore Ts'o2-68/+55
Integrate profile_std_line() into parse_line(), and profile_parse_file() into profile_update_file() to make the code use less memory. Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-03-19Prevent error messages to stderr caused by libblkid calling libdevmapperTheodore Ts'o2-0/+18
Make the libdevmapper fail quietly if blkid is called without root privileges or the kernel does not include device mapper support. (What is the device mapper _library_ doing writing to stderr, anyway?) Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-03-18Fix format statements to make e2fsprogs programs 32-bit cleanTakashi Sato19-61/+80
Change the format string(%d, %ld) for a block number and inode number to %u or %lu. Signed-off-by: Takashi Sato <sho@tnes.nec.co.jp> Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-03-18Change resize2fs open modes for mounted and unmounted filesystemsTheodore Ts'o2-1/+13
If the filesystem is mounted, open it in read-only mode since the userspace program should not try to modify it directly. If the filesystem is not mounted, open it in exclusive mode to avoid potential problems (such as someone trying to mount the filesystem while it is being resized). Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-03-18Change mke2fs to create filesystems with the device opened in exclusive mode.Theodore Ts'o2-1/+6
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-03-18Change e2fsck to open non-mounted filesystems in exclusive modeTheodore Ts'o2-0/+11
Thanks to Andreas Dilger for this idea. If the filesystem is not mounted, e2fsck will open it in exclusive mode to prevent the a confused/careless system administrator from mounting the filesystem while the filesystem check is taking place, which could cause all sorts of problems. Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-03-18Add an option to debugfs to open filesystems in exclusive modeTheodore Ts'o3-8/+16
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-03-18Add EXT2_FLAG_EXCLUSIVE to the ext2fs library.Theodore Ts'o4-5/+21
This flag when specified to ext2fs_open or ext2fs_initialize indicates that the application wants the io_channel to be opened in exclusive mode. Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-03-18Add IO_FLAG_EXCLUSIVE flag to io_channel abstractionTheodore Ts'o3-1/+8
Add a new io_channel open flag, IO_FLAG_EXCLUSIVE,which requests that the device be opened in exclusive (O_EXCL) mode. Add support to the unix_io implementation for this flag. Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-03-18Fix documentation: BLOCK_FLAG_TRAVERSE should be BLOCK_FLAG_DEPTH_TRAVERSETheodore Ts'o4-4/+15
Addresses Debian Bug #351268 Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-03-17Fix build when not building any shared libraries.Theodore Ts'o2-0/+8
Add missing real-subdirs:: line to lib/Makefile.library, so there is a default definition of the real-subdirs target. Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-03-17Document the resize_inode filesystem option in mke2fs man pageTheodore Ts'o1-0/+12
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-03-17Fix a signed vs unsigned bug in calc_reserved_gdt_blocks()Theodore Ts'o2-4/+9
This fixes mke2fs -O resize_inode for very large filesystems (i.e., 20GB). Addresses Debian Bug #346580 Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-03-17Add support for on-line resizing to resize2fsTheodore Ts'o9-96/+364
If the filesystem is mounted, attempt to use the on-line resizing ioctls to resize the filesystem. Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-03-12Fix blkid's last verification logic to work when the system clock is insaneTheodore Ts'o6-7/+25
Users have reported problems on newly installed systems when the Macintosh's system clock battery is dead and the hardware clock is returning a date of 1904. Turns out there were some bugs in handling dates before the Unix epoch. Addresses Red Hat Bug: #182188 probe.c (blkid_verify): Fix the bid_time sanity checking logic, so that if last verification time is more recent than the current time, or the comparison between the last verification time and the current time causes an overflow, a device verification will take place. devname.c (blkid_get_dev): Set the initial bid_time to be INT_MIN, to guarantee that blkid_verify will always be run even when the system clock is insane. dev.c (blkid_debug_dump_dev), read.c (debug_dump_dev), save.c (save_dev): Fix the printf format for dev->bid_time to match the fact that it is an signed type. Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-03-10Fix the subdirs logic so it works with GNU make 3.80Theodore Ts'o8-6/+14
The previous fix which fixed the problem with GNU make 3.81 building all of the library object files caused GNU make 3.80 fail because the subdirectories (such as elfshared) were not getting created. This fix should allow the Makefiles to work with both GNU make 3.80 and GNU make 3.81.
2006-03-10Add EXT_JOURNAL to the blkid tag of ext3 filesystems.Theodore Ts'o4-26/+63
If the filesystem has an external journal, store the UUID of the external journal in the tag EXT_JOURNAL. If the filesystem type has changed, clear all the tags on the device, not just a preset list of LABEL, UUID, TYPE, and SEC_TYPE. Fix a bug so that blkid_set_tag will work correctly when freeing a tag when the input name parameter comes from the tag that we are freeing. Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-03-10Enhance e2fsck so it can fix external journal hint in the superblock Theodore Ts'o6-0/+60
Check to see if the superblock hint for the external journal needs to be updated, and if so, offer to update it. (Addresses Debian Bug: #355644) Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-03-08Remove e2fsck/malloc.hTheodore Ts'o1-231/+0
(This was an artifact of the migration of the sources from BitKeeper to Mercurial; mea culpa, mea maximum culpa --- Ted) Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-03-08Fix debugfs's icheck to correctly report the owner of an EA blockTheodore Ts'o2-2/+7
Hello Ted, here is a minor fixup with debugfs "icheck" finding a block in an EA. It was reporting the inode number as one too low because it was set after the EA check is done. From: Andreas Dilger <adilger@clusterfs.com> Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-03-08Enable devmapper patch for DebianTheodore Ts'o2-2/+3
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-03-08Add device-mapper support to the blkid libraryKarel Zak7-6/+240
On systems where is multi-path storage device is problem with duplicated filesystems. The solution is select "the best" device. This is possible by device-mapper library. Short quotation from RH bugzilla: With my patch, all dm devices remains in libblkid cache. Only the top level dm devices are given high priority and more appropriate node names (i.e. /dev/mapper/*) are used. For example, if we have linear mapped dm device "ov1" over dm device "disk1p3" which is multipath mapped to /dev/sdd3 and /dev/sdh3: # dmsetup.static ls --tree ov1 (253:5) <-- /dev/mapper/ov1 or /dev/dm-5 `-disk1p3 (253:4) <-- /dev/mapper/disk1p3 or /dev/dm-4 `-disk1 (253:0) |- (8:112) <-- /dev/sdh `- (8:48) <-- /dev/sdd Original version of blkid will show: # ./orig/blkid -t LABEL=mpdisk1p3 -l /dev/sdd3: LABEL="mpdisk1p3" ... TYPE="ext3" With my patch, blkid will show: # ./deptree/blkid -t LABEL=mpdisk1p3 -l /dev/mapper/ov1: LABEL="mpdisk1p3" ... TYPE="ext3" In blkid cache, all devices are listed: # ./orig/blkid -t LABEL=mpdisk1p3 /dev/sdd3: LABEL="mpdisk1p3" ... TYPE="ext3" /dev/sdh3: LABEL="mpdisk1p3" ... TYPE="ext3" /dev/dm-4: LABEL="mpdisk1p3" ... TYPE="ext3" /dev/dm-5: LABEL="mpdisk1p3" ... TYPE="ext3" # ./deptree/blkid -t LABEL=mpdisk1p3 /dev/mapper/ov1: LABEL="mpdisk1p3" ... TYPE="ext3" /dev/sdd3: LABEL="mpdisk1p3" ... TYPE="ext3" /dev/sdh3: LABEL="mpdisk1p3" ... TYPE="ext3" /dev/dm-4: LABEL="mpdisk1p3" ... TYPE="ext3" For more details see discussion on: https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=156324 Addresses Red Hat Bug: #156324 Signed-off-by: Karel Zak <kzak@redhat.com> Signed-off-by: Peter Jones <pjones@redhat.com> Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-02-20Update Swedish translationTheodore Ts'o2-7/+7
2006-01-29Add a config option which controls whether fs checks are skipped when on batteryTheodore Ts'o2-2/+13
Whether fs checks are skipped when the system is running on battery can be controlled by the new e2fsck.conf option defer_check_on_battery (this option defaults to TRUE). Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-01-29Print an explanation when skipping a check due being on batteryTheodore Ts'o2-3/+13
On Sat, Jan 28, 2006 at 12:53:33PM -0600, Fredrick Knieper wrote: > Package: e2fsprogs > Version: 1.38+1.39-WIP-2005.12.31-1 > > When running fsck at boot or when running e2fsck manually on a device, > fsck will not check a filesystem based on the maximum mount count, > unless a flag such as -f or -c is used to force the filesystem check. What's happening is that when you run on battery, e2fsck will delay running the filesystem check, on the assumption that it is better to defer the check until some time in the future when your laptop is running on AC mains again. This deferral is not infinite, however; if the number of mounts exceeds twice the max mount counts, or if the interval between checks exceeds twice the check interval, e2fsck will force the check even though you are on battery. I've changed the sources to print a message to make this more clear. Addresses Debian Bug: #350306 Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-01-06Update debian changelog for release.Theodore Ts'o1-0/+21
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-01-06Update priorities and sections to match with Debian override file.Theodore Ts'o1-4/+4
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-01-06Added tag E2FSPROGS-1.39-WIP-1231 for changeset ↵Theodore Ts'o1-0/+1
b3e5c52c10907a4488ded00fca596487643bddc4
2006-01-06Update Dutch, Polish, and Swedish translations. Theodore Ts'o4-392/+214
Addresses Debian Bug: #343149 Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-01-06Set FD_CLOEXEC on the /dev/random file descriptor used by libuuidTheodore Ts'o2-0/+11
This avoids a fd leak across an execve() which was causing problems for the LVM tools. (Addresses Debian Bug: #345832) Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-01-06Add support for quoted strings in tag and section namesTheodore Ts'o2-19/+46
Also changed top-level section name parsing to ignore leading and trailing whitespace. Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-01-05Add support to the profile library for /etc/foo/conf.d style directories Theodore Ts'o2-13/+111
If a directory is passed to profile_init, then read all files which match [0-9a-zA-Z]* in sort order. Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-01-05Fix gcc -Wall warning in profile_helper.cTheodore Ts'o1-1/+1
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-01-05More profile cleanups: remove prf_data_t data structureTheodore Ts'o2-131/+37
Eliminate the prf_data_t data structure and fold it back into prof_file_t. Eschew needless complexity! Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-01-05Enhance profile library's parser to accept comments Theodore Ts'o2-29/+59
This also changes syntax accepted by the profile parser. The value of profile relations must not contain spaces unless it is quoted; otherwise the parser will throw an error. Previously something like this was allowed: [liboptions] test = foo bar Now, the relation must be in double quotes in order to be valid, i.e., "foo bar". Comments are allowed anywhere and can be started with either a ';' or a '#' character. The only place where comments will not be intepreted as beginning a comment is in a quoted string. Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-01-04Add syntax error reporting to the profile libraryTheodore Ts'o4-78/+62
E2fsck will now report syntax errors in /etc/e2fsck.conf intead of simply ignoring the config file when there are errors. Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-01-02Simplify profile core functionalityTheodore Ts'o6-549/+426
Boil down and simplify profile.c, and move extra functionality that's not needed into profile_helpers.c Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-01-02Clean up test driver program for profile.c and #ifdef unused static functionsTheodore Ts'o1-107/+83
Unified batchmode and command-line handling. profile_is_node_final() and profile_find_node_relation() are static, unused functions. Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2006-01-01Fix profile.c so that com_err.h doesn't have to be installedTheodore Ts'o2-1/+7
Fix #include of com_err.h so that it isn't required that the com_err development environment be installed. (Addresses Debian Bug: #345519) Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2005-12-31Update version file for 1.39-WIP-1231 release.Theodore Ts'o1-1/+1
2005-12-31Update e2fsprogs's internationalization files.Theodore Ts'o21-4554/+5395
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2005-12-31Update release notes Theodore Ts'o1-5/+58
2005-12-31Add e2fsck problem handling to be configurableTheodore Ts'o3-4/+48
Add the ability for the e2fsck configuration file to override the behaviour of e2fsck when a particular filesystem problem is encountered. This allows reconnecting an inode to lost+found to not stop the boot sequence, if a system administrator really badly wants this behaviour for some specialized reason, for example. Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2005-12-31Slim down profile.cTheodore Ts'o1-5/+5
#ifdef out functions not needed by e2fsck. Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2005-12-31Add E2FSCK_CONFIG environment variableTheodore Ts'o2-0/+5
Also, use this environtment variable to make sure that a local /etc/e2fsck.conf file will not interfere with the regression test suite. Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2005-12-31Fix Really Ancient debian changelog lines so that Lintian doesn't complain.Theodore Ts'o1-26/+41
2005-12-31Make sure debian/rules is executable.Theodore Ts'o1-0/+0
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2005-12-31Fix incorrect location of prof_err.h in profile.c.Theodore Ts'o2-4/+4
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2005-12-31Update debian/changelog file.Theodore Ts'o1-0/+21
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2005-12-31Move the blkid and uuidgen programs out of library packages and into e2fsprogsTheodore Ts'o3-5/+1
Move the blkid and uuidgen binaries out of libblkid1 and libuuid1 and into the e2fsprogs package to support soname transitions and simulaneous installs of multiarch flavors to coexist. (It's not worth creating two whole new packages for two separate binaries, so we just fold them into e2fsprogs.) (Closes: #330737, #330736) Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>