I am trying to make a backup of a very big postgresql(around 165 gb) for two days now. and at last I find out my mistake. never take a dump at same disk. it eats a lot of IO and kill all services which depends to dumped database.
first try I am dumping database to same disk and after around 6 hours web server started to giving timeout and lovely sitescope mails :) and I had to kill that process.
then I read a lot and started to dumping the database to another machine and it was smooth took around 4 hours to dump and no web server gave any timeout.
example commands
pg_dump -Fc dbname > db.backup
and I started restore like this
pg_restore -d dbname db.backup
before that I needed to recreate the db from psql. and this have not finished I must tell that pg_restore has -j parameter which gives more thread to read the dump file and you can give cpu number to -j which will work faster.
Subscribe to:
Post Comments (Atom)
speed test glasgow
at first test upload was 20mbps, something broke it now it gives 0.07 but I am happy with 129 download and price is 16 £
-
I know its been a long time I have not write anything. because I have not learn or done any new things. I dont want to write regular meaning...
-
After iphone 16 I wanted to test an android and looks like sony xperia 10 VI is nice, which is 6.1 inches, but it was narrow and longer than...
-
in .net 2 if you want to show your application in system tray . you need to add notify icon to your application and set the "ShowInTas...
No comments:
Post a Comment