- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- mysql dump
Operating System - Linux
1820693
Members
2797
Online
109627
Solutions
Forums
Categories
Company
Local Language
юдл
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Discussions
Forums
Forums
Discussions
юдл
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-18-2007 12:47 AM
тАО06-18-2007 12:47 AM
mysql dump
Hi there
A nead to build command to backup mysql loging from remote host (host A), the files shoud be stored on host A but database exist at host b.
I was trying :
mysqldump -h myhost.com -u test -ptest2 test > /home/admin/
But it's not working.
Can anyone help ?
A nead to build command to backup mysql loging from remote host (host A), the files shoud be stored on host A but database exist at host b.
I was trying :
mysqldump -h myhost.com -u test -ptest2 test > /home/admin/
But it's not working.
Can anyone help ?
Jesus is the King
2 REPLIES 2
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-18-2007 12:54 AM
тАО06-18-2007 12:54 AM
Re: mysql dump
I'm going to assume the username and password pair you're using are valid for the 'test' database..
With that, the only issue I really see is that you're trying to redirect to a directory, when you need to be redirecting to a file, i.e.
mysqldump -hmyhost.com -utest -ptest2 test > /home/admin/test-dump.sql
Depending on the table types, and how often the tables are used, you might want to look at '--opt' and '-q' flags to 'mysqldump'.
With that, the only issue I really see is that you're trying to redirect to a directory, when you need to be redirecting to a file, i.e.
mysqldump -hmyhost.com -utest -ptest2 test > /home/admin/test-dump.sql
Depending on the table types, and how often the tables are used, you might want to look at '--opt' and '-q' flags to 'mysqldump'.
One long-haired git at your service...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-18-2007 01:31 AM
тАО06-18-2007 01:31 AM
Re: mysql dump
mysqldump needs a file to dump it's data in, not a directory.
If you want to load the dump on another host (say: Host B, which already has the same database) you can make it add a dropline for that database (BE SURE there is no vital information in that database as it's going to be dropped!!!) with option:
--add-drop-database
But I think you're talking about a full db export & import. --opt is recommended for that (also enables add-drop-table by default)
So you'd have something like:
mysqldump -h host -utest -ptest --add-drop-database --databases testdb > testdb.sql
If you want to load the dump on another host (say: Host B, which already has the same database) you can make it add a dropline for that database (BE SURE there is no vital information in that database as it's going to be dropped!!!) with option:
--add-drop-database
But I think you're talking about a full db export & import. --opt is recommended for that (also enables add-drop-table by default)
So you'd have something like:
mysqldump -h host -utest -ptest --add-drop-database --databases testdb > testdb.sql
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Learn About
News and Events
Support
© Copyright 2025 Hewlett Packard Enterprise Development LP