Pages

Linux File System

Features of ext3
The ext3 _le system is essentially an enhanced version of the ext2 _le system. These improvements
provide the following advantages:

Availability
After an unexpected power failure or system crash (also called an unclean system shutdown),
each mounted ext2 _le system on the machine must be checked for consistency by the e2fsck
program. This is a time-consuming process that can delay system boot time signi_cantly, especially
with large volumes containing a large number of _les. During this time, any data on the
volumes is unreachable.
The journaling provided by the ext3 _le system means that this sort of _le system check is no
longer necessary after an unclean system shutdown. The only time a consistency check occurs
using ext3 is in certain rare hardware failure cases, such as hard drive failures. The time to
recover an ext3 _le system after an unclean system shutdown does not depend on the size of the
_le system or the number of _les; rather, it depends on the size of the journal used to maintain
consistency. The default journal size takes about a second to recover, depending on the speed of
the hardware.

Data Integrity
The ext3 _le system provides stronger data integrity in the event that an unclean system shutdown
occurs. The ext3 _le system allows you to choose the type and level of protection that your data
receives. By default, Red Hat Linux 8.0 con_gures ext3 volumes to keep a high level of data
consistency with regard to the state of the _le system.
Speed
Despite writing some data more than once, ext3 has a higher throughput in most cases than
ext2 because ext3's journaling optimizes hard drive head motion. You can choose from three
journaling modes to optimize speed, but doing so means trade offs in regards to data integrity.
Easy Transition
It is easy to change from ext2 to ext3 and gain the bene_ts of a robust journaling _le system
without reformatting. See Section 1.3 for more on how to perform this task.
If you perform a fresh installation of Red Hat Linux 8.0, the default _le system assigned to the system's
Linux partitions is ext3. If you upgrade from a version of Red Hat Linux that uses ext2 partitions, the
installation program allows you to convert these partitions to ext3 partitions without losing data. See
the appendix titled Upgrading Your Current System in the Of_cial Red Hat Linux Installation Guide
for details.
The following sections will walk you through the steps for creating and tuning ext3 partitions. If you
have ext2 partitions and are running Red Hat Linux 8.0, you can skip the partitioning and formating
sections below and go directly to Section 1.3.

Creating an ext3 File System
After installation, it is sometimes necessary to create a new ext3 _le system. For example, if you add
a new disk drive to a Red Hat Linux system, you may want to create partition the drive and use the
ext3 _le system.
The steps for creating an ext3 _le system are as follows:
1. Create the partition using parted or fdisk.
2. Format the partition with the ext3 _le system using mkfs.
3. Label the partition using e2label.
4. Create the mount point.
5. Add the partition to /etc/fstab.
Refer to Chapter 5 for information on performing these steps.

Converting to an ext3 File System
The tune2fs program can add a journal to an existing ext2 _le system without altering the data
already on the partition. If the _le system is already mounted while it is being transitioned, the journal
will be visible as the _le .journal in the root directory of the _le system. If the _le system is not
mounted, the journal will be hidden and will not appear in the _le system at all.
To convert an ext2 _le system to ext3, log in as root and type:
/sbin/tune2fs -j /dev/hdbX
In the above command, replace /dev/hdb with the device name and X with the partition number.
After doing this, be certain to change the partition type from ext2 to ext3 in /etc/fstab.
If you are transitioning your root _le system, you will have to use an initrd image (or RAM disk) to
boot. To create this, run the mkinitrd program. For information on using the mkinitrd command,
type man mkinitrd. Also make sure your GRUB or LILO con_guration loads the initrd.
If you fail to make this change, the system will still boot, but the _le system will be mounted as ext2
instead of ext3.

Reverting to an ext2 File System
Because ext3 is relatively new, some disk utilities do not yet support it. For example, you may need
to shrink a partition with resize2fs, which does not yet support ext3. In this situation, it may be
necessary to temporarily revert a _le system to ext2.
To revert a partition, you must _rst unmount the partition by logging in as root and typing:
umount /dev/hdbX
In the above command, replace /dev/hdb with the device name and X with the partition number. For
the remainder of this section, the sample commands will use hdb1 for these values.
Next, change the _le system type to ext2 by typing the following command as root:
/sbin/tune2fs -O ^has_journal /dev/hdb1
Check the partition for errors by typing the following command as root:
/sbin/e2fsck -y /dev/hdb1
Then mount the partition again as ext2 _le system by typing:
mount -t ext2 /dev/hdb1 /mount/point
In the above command, replace /mount/point with the mount point of the partition.
Next, remove the .journal _le at the root level of the partition by changing to the directory where it
is mounted and typing:
rm -f .journal
You now have an ext2 partition.
If you permanently change the partition to ext2, remember to update the /etc/fstab _le.


Configuration on Router for Transparent Proxy

Router#config t
Router(config)#ip access-list extended 110
Router(config-ext-nacl)# deny tcp any any neq www
Router(config-ext-nacl)# deny tcp host 202.125.142.116 any
Router(config-ext-nacl)# permit tcp any any
Router(config-ext-nacl)#end
Router(config)# route-map proxy permit 5
Router(config)# match ip address 110
Router(config)# set ip next-hop 202.125.142.116
Router(config)#int fa0/1
Router(config-if)# ip policy route-map proxy
Router(config-if)#end
Router#copy ru st

Forex Trading