Welcome to the most active Linux Forum on the web.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 08-10-2009, 10:37 AM   #1
Registered: Jul 2009
Posts: 36

Rep: Reputation: 0
cygwin scp problem


I'm trying to copy a file from cygwin to centos via scp.

All files that I'm sending over ends up with som strange caracters at the end. Like "?" and "^M".

Does anybody know why?

Best regards

Old 08-10-2009, 11:02 AM   #2
LQ Guru
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 677Reputation: 677Reputation: 677Reputation: 677Reputation: 677Reputation: 677
You are sending Windows text files. They end in \n\r. Linux files end in \n. You can use the "dos2unix" command to convert them. Always convert config files and make files.

There was an option when you installed cygwin asking which kind of text files to use in cygwin itself.
Old 08-10-2009, 11:03 AM   #3
LQ Guru
Registered: Dec 2008
Location: Westgate-on-Sea, Kent, UK
Distribution: Debian Testing Amd64
Posts: 5,465

Rep: Reputation: Disabled
Yes, Windows files have a slightly different way of ending lines. *nix based systems use LF but Windows uses LF+CR that's the ^M you're seeing. I don't know about the "?".


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
cygwin problem Linux - Newbie 4 04-17-2009 01:50 AM
SCP to windows with cygwin Bth8 Linux - Networking 1 04-14-2009 11:17 AM
Have you ever used cygwin, i've met a problem with the command stat from cygwin andy820303 Linux - Newbie 0 03-11-2009 04:37 AM
scp does not work and gives the following error message: scp: FATAL: Executing ssh1 i akay Linux - Networking 16 09-29-2008 12:41 AM
a problem about cygwin tony_bupt Linux - Newbie 4 09-05-2004 08:50 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:43 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration