dumping data and compressing


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers dumping data and compressing
# 1  
Old 11-23-2004
dumping data and compressing

I have a utility provided by our vendor to dump data from their system. It is

expsysdb -s prod proddata.dmp

"-s" and "prod" are parameters and "proddata.dmp" is the file name that the data is dumped to (this can be any name). Our current system (AIX 4.3) has a file size limit set to 1 gig and as you can imagine I am running up againts this limit. Is there a way that I can have the output compressed at the same time that it is being dumped to a file? The reason I need to do this is we have set up a new system and I need to transfer the data to this system. I have used named pipes when transfering the data between two applications on the same machine, but not sure how to work this when it needs to be transferred to another machine. For example I used this to load the data under one session:
impexp -f test named.pipe

Then loged in another session (same user id) and started to dump the data like this:
expsysdb -s prod named.pipe

If you can give me some ideas that would be great or even point me to some examples. Thank you.
# 2  
Old 11-23-2004
Try your named pipe trick again. But start a gzip (or whatever other compression program you use) to read from it. Then start your dump program writing to it.
# 3  
Old 11-23-2004
Thank you. I tried this:
mknod lawpipe.pipe p
gzip -c lawpipe.pipe > test.gz

I get the following error:
gzip: lawpipe.pipe is not a directory or a regular file - ignored
# 4  
Old 11-23-2004
Then try:
gzip < named.pipe > outputfile
# 5  
Old 11-23-2004
Perfect. Thank you very much. You have made my life much easier.
# 6  
Old 11-24-2004
Hi,
A couple more questions. Can you explain a little more how the command works? For instance, what do the arrows (<named.pipe>) on either side of the named.pipe signify? Also, is it possible to run this in background? Again, thank you for your help.
# 7  
Old 11-24-2004
command < inputfile

just specifys an input file for command. This makes the shell open the file and run the command with the file already opened. Some commands can open their own input files. But as you saw here, some of them perform screwball tests and refuse to open perfectly good files. So I prefer this syntax.

command > outputfile is the same deal but in the other direction. This is more often the only game in town because lots of commands can't open an output file...the shell must do it for them.

command < inputfile > outputfile &
will place the command in the background, but it exit if you close the session.

nohup command < inputfile > outputfile &
will background the command and protect it from hangup signals. So it will continue if you close the session.
 
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Dumping database results and doing checksums

hey I am dumping two database results into two text files and doing checksums on them. Anyone know how to do this. I originally was doing line by line comparison and diff but I need something faster for larger gb size files. anyone got tips? (5 Replies)
Discussion started by: Samuel12
5 Replies

2. Shell Programming and Scripting

Dumping mysql through ssh tunnel

Hello wise scripters This is my first post and I am glad to join this community. I am trying to make work a mysqldump via ssh tunnel in a shell script. The problem is that running this sequence of commands manually works fine, but when I put these in a bash script they give me the following... (8 Replies)
Discussion started by: Solidus
8 Replies

3. IP Networking

dumping traffic of a singel application

I would like to know if there is a way to dump the network traffic of a single application. I tried with tcpdump but I couldn't find a way. Is there a patch, which enables that or does someone know an other application to do this? (2 Replies)
Discussion started by: smf15
2 Replies

4. Red Hat

Core Dumping?

How to now if the server is core dumping into the same filesystem? (4 Replies)
Discussion started by: 300zxmuro
4 Replies

5. Programming

strcat() dumping core

strcat dumping core in the situation like main() { char* item; char* p=sat_item; char type; item=(char*) malloc(strlen(p)); strncpy(type,p,4); type='\0'; strcat(item,type); //dumping core } I couldn't get why strcat dumping core? (3 Replies)
Discussion started by: satish@123
3 Replies

6. UNIX for Dummies Questions & Answers

Dumping network packets

Hi, My Solaris Workstation has got 4 NICS, out of which one of them(bge3) is unplugged from the rest of the external network & connected to other interface(bge1). The isolated NIC serves as a simulated Ethernet Interface for my application under development. Now, I'd like to capture RAW... (1 Reply)
Discussion started by: smanu
1 Replies

7. UNIX for Dummies Questions & Answers

dumping to tape from /tmp

I'm trying to dump files to tape and im just wondering can i dump from /tmp swap partition? ufsdump 0ubf 126 /dev/rmt/1 swap/tmp/blah.tar DUMP: Cannot open dump device `swap/tmp/blah.tar': No such file or directory ufsdump 0ubf 126 /dev/rmt/1 /tmp/NotificationServer_1.bku DUMP:... (1 Reply)
Discussion started by: kingdbag
1 Replies

8. UNIX for Advanced & Expert Users

Dumping multiple Folders

How would i go about dumping my /home/ directory and my /root directory i currently have..... dump -f /root/backup.dp /home/ /root/ ...but dump only seems to see only my first source directory and not the second (/root in this case) anyone know a way around this..or if it is even... (1 Reply)
Discussion started by: Freakytah
1 Replies

9. UNIX for Dummies Questions & Answers

Dumping files to tape

Can anyone please help.... how can I dump just a single file to tape using the ufsrestore command!!! I'm a newbie to unix and It's driving me mad.. Thanks in advance. (2 Replies)
Discussion started by: Jonathan
2 Replies
Login or Register to Ask a Question