Re: Is it safe to run "tune2fs -j" on a mounted filesystem?

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

 



On Mar 20, 2003  01:41 -0500, Bryan J. Smith wrote:
> I'm curious is if it safe or even wise to run the following command on a
> mounted filesystem, namely root (/)?
>   tune2fs -j /dev/hda1

Yes, this is possible (and safe) to do.  It will create a file /.journal
for the journal (and set the has_journal) flag in the superblock along
with the inode number of the journal.  Of course, since the filesystem
is mounted as ext2, it will not suddenly become "journaled" until it
is unmounted and remounted as ext3.
 
> What about if someone goes into single user mode and runs this first?
>   mount -o remount,ro /

Won't work, I'm pretty sure.

> And then to enable it, runs this?
>   mount -t ext2 -o remount,rw /

Never.  While ext2 and ext3 share an on-disk format, the kernel code
is very different.  The above will remount the filesystem as ext2,
and it will totally ignore the journal.

Cheers, Andreas
--
Andreas Dilger
http://sourceforge.net/projects/ext2resize/
http://www-mddsp.enel.ucalgary.ca/People/adilger/



_______________________________________________

Ext3-users@redhat.com
https://listman.redhat.com/mailman/listinfo/ext3-users

[Index of Archives]         [Linux RAID]     [Kernel Development]     [Red Hat Install]     [Video 4 Linux]     [Postgresql]     [Fedora]     [Gimp]     [Yosemite News]

  Powered by Linux