Sponsored Content
Special Forums UNIX and Linux Applications Single table or split the table Post 302769541 by 47shailesh on Tuesday 12th of February 2013 03:15:08 PM
Old 02-12-2013
@before4 you didn't mentioned how you'll use the logs.

In my opinion storing in mysql is better than flat files. querying become really easy.
Make sure to partition your table like on date & server_name eg: partition for every day and create local indexes based on kind of usage you want.

Last edited by 47shailesh; 02-12-2013 at 06:30 PM.. Reason: location=local typo correction
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Check the record count in table (table in oracle)

I have requirement: 1) Check the record count in table (table in oracle) 2) If records exists generate the file for existing records and wait for some time (Go to sleep mode) and Again check the record count after 10 min.......... (Loop this process if record count >0). 3) Generate touch... (1 Reply)
Discussion started by: kamineni
1 Replies

2. Shell Programming and Scripting

Check the record count in table (table in oracle)

I have requirement: 1) Check the record count in table (table in oracle) 2) If records exists generate the file for existing records and wait for some time then Go to sleep mode and Again check the record count after 10 min.......... (Loop this process if record count >0). 3) Generate touch... (1 Reply)
Discussion started by: kamineni
1 Replies

3. Shell Programming and Scripting

select values from db1 table and insert into table of DB2

Hi I am having three oracle databases running in three different machine. their ip address is different. from one of the DB am able to access both the databases.(means am able to select values and insert values in to tables individually.) I need to fetch some data from DB1 table(say DB1 ip is... (2 Replies)
Discussion started by: aemunathan
2 Replies

4. UNIX and Linux Applications

create table via stored procedure (passing the table name to it)

hi there, I am trying to create a stored procedure that i can pass the table name to and it will create a table with that name. but for some reason it creates with what i have defined as the variable name . In the case of the example below it creates a table called 'tname' for example ... (6 Replies)
Discussion started by: rethink
6 Replies

5. UNIX for Dummies Questions & Answers

Creating a condensed table from a pre-existing table in putty

Hello, I'm working with putty on Windows 7 professional and I'd like to know if there's a way to gather specific lines from a pre-existing table and make a new table with that information. More specifically, I'd like the program to look at a specific column, say column N, and see if any of the... (5 Replies)
Discussion started by: Deedee393
5 Replies

6. Shell Programming and Scripting

Build a table from a list by comparing existing table entries

I am new to this shell scripting.... I have a file which contains list of users. This files get updated when new user comes into the system. I want to create script which will give a table containing unique list of users. When I say unique, it means script should match table while parsing... (3 Replies)
Discussion started by: dchavan1901
3 Replies

7. UNIX and Linux Applications

Help in copying table structure to another table with constraints in Oracle

hi, i need to copy one table with data into another table, right now am using create table table1 as select * from table2 i want the constraints of table1 to be copied to table2 also , can anyone give me some solution to copy the constraints also, now am using oracle 10.2.0.3.0... (1 Reply)
Discussion started by: senkerth
1 Replies

8. Shell Programming and Scripting

awk to convert table-by-row to matrix table

Hello, I need some help to reformat this table-by-row to matrix? infile: site1 A:o,p,q,r,s,t site1 C:y,u site1 T:v,w site1 -:x,z site2 A:p,r,t,v,w,z site2 C:u,y site2 G:q,s site2 -:o,x site3 A:o,q,s,t,u,z site3 C:y site3 T:v,w,x site3 -:p,routfile: SITE o p q r s t v u w x y... (7 Replies)
Discussion started by: yifangt
7 Replies

9. Web Development

Getting Rid of Annoying Bootstrap Table Borders and Wayward Table Lines

Bootstrap is great; but we have had some issues with Bootstrapped <tables> (and legacy <fieldset> elements) showing annoying, wayward lines. I solved that problem today with this simple jQuery in the footer: <script> $(function(){ $('tr, td, fieldset,... (0 Replies)
Discussion started by: Neo
0 Replies

10. UNIX for Beginners Questions & Answers

Read Table in file and split

HELLO I need your help please , i need to read a file that contain a table like : Name | Status ------------------ DB 1 | UP DB 2 | UP DB 3 | DOWN DB 4 | UP DB 5 | UP the objective to read each line and check if DB is UP or Down and give me the name of Down database.... (10 Replies)
Discussion started by: Abdellah
10 Replies
chpt(8) 						      System Manager's Manual							   chpt(8)

Name
       chpt - change a disk partition table

Syntax
       /etc/chpt [ -a ] [ -d ] [ -q ] [ -v ] [ [ -px offset size ] ... ] device

Description
       The  command  lets  you alter the partition sizes of a disk pack.  Using you can tailor your system disks and their partitions to suit your
       system's individual needs.

       If you want to create a file system on a partition that has been modified, you must use

       The standard procedure to change a partition table is:

       1. Look at the current partition table using the -q option.

       2. If a file system does not exist on the a partition, create one using the command.

	  If a file system exists on the a partition but does not contain a partition table in its superblock, copy the partition table  from  the
	  driver to the superblock using the command with the -a option.

       3. Change the partition offsets and sizes using the -px option.	You can change all the partitions for one pack on one command line.

       The  device  must be either the a or c partition of the raw device, depending upon where the file system resides.  For example, if the file
       system resides in the a partition of an RM05 in drive 0, device is rhp0a.

       A file system must exist on the a or c partition of the pack.  If you do not have a file system there, create one using

Options
       -a    Copies the partition table in the device driver to the disk pack.

       -d    Copies the default partition table to the disk pack and to the current partition table in the driver.  The default partition table is
	     the table that was built with the disk driver.

       -q    Runs without modifying the partition tables.  This prints the partition table of the specified disk pack.	It prints the default par-
	     tition table in the driver if there is no partition table on the disk pack.

       -v    Prints verbose messages showing the progress of

       -px   Changes the parameters of partition x on the disk pack to the specified offset and size.  x is the partition you are modifying (a, b,
	     c,  d,  e, f, g, or h).  Offset is the new beginning sector, and size is the new total number of sectors of the partition being modi-
	     fied.

Examples
       This example shows how to change the partition table on an RM05 disk pack in drive 1.  The commands in this example change the the size	of
       the h partition to include the g partition.  Comments are in parenthesis to the right of commands.
       % chpt -q /dev/rhp1a	(view partition table)
       /dev/rhp1a
       No partition table found in superblock...
       using default table from device driver.
       Current partition table:
       partition       bottom	    top      size    overlap
	   a		    0	  15883     15884    c
	   b		16416	  49855     33440    c
	   c		    0	 500383    500384    a,b,d,e,f,g,h
	   d	       341696	 357579     15884    c,g
	   e	       358112	 414047     55936    c,g
	   f	       414048	 500287     86240    c,g
	   g	       341696	 500287    158592    c,d,e,f
	   h		49856	 341201    291346    c
       %
       In  all	of  the tables generated by bottom is the offset (starting sector), top is the ending sector, and size is the number of sectors in
       the partition.  The overlap is the other sectors that are partially or entirely included in the partition.
       % bc		   (basic calculator)
       500287-49856	   (top of g minus bottom of h)
       450431
       450431+1 	   (add 1 because it is zero-based)
       450432		   (size of new h partition)
       %

       From the query, you can see that there is no partition table in the superblock of the a partition.  If this is because  there  is  no  file
       system in the a partition, run the command to create one.

       For this example, assume that there is a file system in the a partition of the disk, but the file system does not contain a partition table
       in its superblock.  Therefore, run with the -a option to copy the partition table in the driver to the superblock of the a partition.
       % chpt -a /dev/rhp1a	(add table to a partition)
       %

       Now you have a partition table to change.
       % chpt -v -ph 49856 450432 /dev/rhp1a   (change h)
       /dev/rhp1a
       New partition table:
       partition       bottom  top     size    overlap
	   a		    0	15883	15884  c
	   b		16416	49855	33440  c
	   c		    0  500383  500384  a,b,d,e,f,g,h
	   d	       341696  357579	15884  c,g,h
	   e	       358112  414047	55936  c,g,h
	   f	       414048  500287	86240  c,g,h
	   g	       341696  500287  158592  c,d,e,f,h
	   h		49856  500287  450432  c,d,e,f,g
       %

Caution
       Changing partition tables indiscriminately can result in losing large amounts of data.

       Check for file systems on all the partitions of the disk before using the -p option.  If a  file  system  exists  whose	partition  may	be
       destroyed, copy it to a backup medium.  After you have changed the partitions, restore the backed up file system.

Restrictions
       You must have superuser privileges to use

       You  can not shrink or change the offset of a partition with a file system mounted on it or with an open file descriptor on the entire par-
       tition.

       You can not change the offset of the a partition.

See Also
       ioctl(2), disktab(5), fsck(8), mkfs(8), newfs(8)
       Guide to System Disk Maintenance

																	   chpt(8)
All times are GMT -4. The time now is 12:11 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy