Skip to content
pvmehta.com

pvmehta.com

  • Home
  • About Me
  • Toggle search form
  • Oracle 10g Installation/Applying Patches Tips Oracle
  • find_pk.sql /* Find Primary Key */ Oracle
  • 751131.1 New Article Error 2819 While Requesting a Systemstate Dump Oracle
  • Establishing trusted relationship between dbmonitor( central monitoring) and monitoring targets. Linux/Unix
  • CPU Core related projections AWS
  • how to find OS block size Oracle
  • Rollback force for distributed transactions Oracle
  • metalink all dynamic view reference notes. Oracle
  • Roles and Stored Object behaviour Oracle
  • alter database backup controlfile to trace Oracle
  • ORA-8031 issue and solution if it is occuring due to truncate. Oracle
  • Configure ssh authentications for RAC Oracle
  • telnet listening Linux/Unix
  • move_arch_files.ksh Linux/Unix
  • Oracle 10g Wait Model Oracle

Adding a new disk and mount it automatically. on VMWARE LINUX

Posted on 30-Jan-2010 By Admin No Comments on Adding a new disk and mount it automatically. on VMWARE LINUX

Adding a new disk and mount it automatically.

Step-1 Add virtual disk to vmware server.

=========================================

Step-2 Bounce the box

=========================================

Step-3 Make sure the new hard drive should be identified by your linux box.

=========================================

As following example, you can see I added /dev/sdc worth of 20GB.

[root@oem ~]# fdisk -l

Disk /dev/sda: 10.7 GB, 10737418240 bytes

255 heads, 63 sectors/track, 1305 cylinders

Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System

/dev/sda1 * 1 19 152586 83 Linux

/dev/sda2 20 1305 10329795 8e Linux LVM

Disk /dev/sdb: 21.4 GB, 21474836480 bytes

255 heads, 63 sectors/track, 2610 cylinders

Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System

/dev/sdb1 1 2610 20964793+ 83 Linux

Disk /dev/sdc: 21.4 GB, 21474836480 bytes

255 heads, 63 sectors/track, 2610 cylinders

Units = cylinders of 16065 * 512 = 8225280 bytes

Disk /dev/sdc doesn’t contain a valid partition table

Step-4 Create the partition as following.

=========================================

[root@oem ~]# fdisk /dev/sdc

Device contains neither a valid DOS partition table, nor Sun, SGI or OSF disklab el

Building a new DOS disklabel. Changes will remain in memory only,

until you decide to write them. After that, of course, the previous

content won’t be recoverable.

The number of cylinders for this disk is set to 2610.

There is nothing wrong with that, but this is larger than 1024,

and could in certain setups cause problems with:

1) software that runs at boot time (e.g., old versions of LILO)

2) booting and partitioning software from other OSs

(e.g., DOS FDISK, OS/2 FDISK)

Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)

Command (m for help): n

Command action

e extended

p primary partition (1-4)

p

Partition number (1-4): 1

First cylinder (1-2610, default 1):

Using default value 1

Last cylinder or +size or +sizeM or +sizeK (1-2610, default 2610):

Using default value 2610

Command (m for help): p

Disk /dev/sdc: 21.4 GB, 21474836480 bytes

255 heads, 63 sectors/track, 2610 cylinders

Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System

/dev/sdc1 1 2610 20964793+ 83 Linux

Command (m for help): w

The partition table has been altered!

Calling ioctl() to re-read partition table.

Syncing disks.

[root@oem ~]#

Step-5 Validate the partition as following:

===========================================

In following information, you are seeing /dev/sdc1, this is the new partition that I created just now.

[root@oem ~]# fdisk -l

Disk /dev/sda: 10.7 GB, 10737418240 bytes

255 heads, 63 sectors/track, 1305 cylinders

Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System

/dev/sda1 * 1 19 152586 83 Linux

/dev/sda2 20 1305 10329795 8e Linux LVM

Disk /dev/sdb: 21.4 GB, 21474836480 bytes

255 heads, 63 sectors/track, 2610 cylinders

Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System

/dev/sdb1 1 2610 20964793+ 83 Linux

Disk /dev/sdc: 21.4 GB, 21474836480 bytes

255 heads, 63 sectors/track, 2610 cylinders

Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System

/dev/sdc1 1 2610 20964793+ 83 Linux

[root@oem ~]#

Step-6 Create ext3 file system as following.

=====================================================

[root@oem ~]# mke2fs -j /dev/sdc1

mke2fs 1.39 (29-May-2006)

Filesystem label=

OS type: Linux

Block size=4096 (log=2)

Fragment size=4096 (log=2)

2621440 inodes, 5241198 blocks

262059 blocks (5.00%) reserved for the super user

First data block=0

Maximum filesystem blocks=4294967296

160 block groups

32768 blocks per group, 32768 fragments per group

16384 inodes per group

Superblock backups stored on blocks:

32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,

4096000

Writing inode tables: done

Creating journal (32768 blocks): done

Writing superblocks and filesystem accounting information: done

This filesystem will be automatically checked every 27 mounts or

180 days, whichever comes first. Use tune2fs -c or -i to override.

[root@oem ~]#

Step-7 Create the mount folder.

==================================================

[root@oem ~]#

[root@oem ~]# cd /

[root@oem /]# mkdir u02

[root@oem /]# ls -rlt /u02

total 0

[root@oem /]#

Step-8 Mount the file system to /u02 manually for test

======================================================

[root@oem /]# mount /dev/sdc1 /u02

[root@oem /]# df -k /u02

Filesystem 1K-blocks Used Available Use% Mounted on

/dev/sdc1 20635700 176200 19411264 1% /u02

[root@oem /]#

[root@oem /]# df -k

Filesystem 1K-blocks Used Available Use% Mounted on

/dev/mapper/VolGroup00-LogVol00

7935392 5385392 2140400 72% /

/dev/sda1 147764 12189 127946 9% /boot

tmpfs 601112 0 601112 0% /dev/shm

/dev/sdb1 20635700 18561860 1025604 95% /u01

/dev/sdc1 20635700 176200 19411264 1% /u02

[root@oem /]#

Step-9 Mount the filesystem automatically, when your Linux starts

=================================================================

Put following entry in /etc/fstab

/dev/sdc1 /u02 ext3 rw 0 0

Step-10 Validate whether automount is working or not by bouncing the instance.

=============================================================================

Linux/Unix, shell

Post navigation

Previous Post: sqlnet.ora paramters
Next Post: Good Oracle Architecture In Short and point to point

Related Posts

  • Guide to Linux System Command Mastery Linux/Unix
  • How to find Unix server conguraiton including Server Model number and underlying disk sub-system ( On Solaris) Linux/Unix
  • Follwoing korn shell is used to move files from source folder to destination folder and gzip it in destination folder. mv_iotto.ksh Linux/Unix
  • oracle 10g on linux Linux/Unix
  • Deleting first line and lastline of a file using sed Linux/Unix
  • Reading parameter file and printing Linux/Unix

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Categories

  • Ansible (0)
  • AWS (2)
  • Azure (1)
  • Linux/Unix (149)
  • MYSQL (5)
  • Oracle (392)
  • PHP/MYSQL/Wordpress (10)
  • POSTGRESQL (0)
  • Power-BI (0)
  • Python/PySpark (7)
  • RAC (17)
  • rman-dataguard (26)
  • shell (149)
  • SQL scripts (341)
  • SQL Server (6)
  • Uncategorized (0)
  • Videos (0)

Recent Posts

  • SQL Server Vs Oracle Architecture difference25-Jul-2025
  • SQL Server: How to see historical transactions25-Jul-2025
  • SQL Server: How to see current transactions or requests25-Jul-2025
  • T-SQL Vs PL/SQL Syntax25-Jul-2025
  • Check SQL Server edition25-Jul-2025
  • Checking SQL Server Version25-Jul-2025
  • Oracle vs MYSQL Architecture differences (For DBAs)24-Jul-2025
  • V$INSTANCE of Oracle in MYSQL24-Jul-2025
  • Day to day MYSQL DBA operations (Compared with Oracle DBA)24-Jul-2025
  • MYSQL and Oracle Comparison for Oracle DBA24-Jul-2025

Archives

  • 2025
  • 2024
  • 2023
  • 2010
  • 2009
  • 2008
  • 2007
  • 2006
  • 2005
  • Oracle10g – Using SQLAccess Advisor (DBMS_ADVISOR) with the Automatic Workload Repository Oracle
  • plan10g.sql Oracle
  • Good Doc 28-JUN-2006 Oracle
  • Committing distributed transaction using commit force Oracle
  • This is im telling Kishore Oracle
  • get_vmstat.ksh Linux/Unix
  • Sort with ASCII order and Numeric Order Linux/Unix
  • oracle Dba site Oracle

Copyright © 2025 pvmehta.com.

Powered by PressBook News WordPress theme