Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I'm not sure if this is the right place for this thread, but here it is.
I do a database backup through the shell and write the dump to a file, but the file names end up looking like db1.sql?, db2.sql?, db3.sql. :'( When I include the proper files names in a cron job for tar (doing a site backup), the tar doesn't complete because it can't find those files.
Why are there question marks at the ends of the file names?
How can I get my script to not generate or fix the question marks?
Yes, I created it on Windows. I actually copied the script from somewhere on the Internet. It works great with just one file. The 4 was leftover from my user name... I forgot to get rid of that part, too. I changed the script to have a space between the user name and password flags and values. Do these things have to do with the question marks?
Note that usually there is a space between the flag and the value eg -u username, but -p is an exception, there should be no space, thus: -ppasswd
See the link I gave you.
HTH
PS Please add your distro to your profile so we can see it, and post the ver of MySQL as well.
Thanks for the quick response. :-) I added the dos2unix program to my script and it seems to be working the way I expect. Thanks. :-D I have dos2unix in the script in case I change the sh file on my Windows box.
I changed the mysqldump stuff like you mentioned and was listed in the manual. I think it was the \r\n stuff that was appending ? to all of the sql files. Adding that program call seemed to work just fine.
mysql 5.0.51a is the version installed on the server.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.