[GH-ISSUE #34] FYI: Wrong EOL (End of Line) for Unix #3

Closed
opened 2026-03-07 19:11:22 +03:00 by kerem · 3 comments
Owner

Originally created by @pitchea on GitHub (Jan 18, 2024).
Original GitHub issue: https://github.com/007revad/Synology_enable_M2_card/issues/34

Between version v3.0.9 and v3.0.11 the EOL changed from LF to CRLF. When I ran the 'syno_enable_m2_card.sh' (v3.0.11) script on my Syno DS1621+ I got the following error:

/usr/bin/env: ‘bash\r’: No such file or directory

where the \r is a result of the CR from the Windows EOL encoding instead of the UNIX EOL encoding. Swapping it back to LF, the script works perfectly.

v3.0.11:
image

v3.0.9:
image

Similar thing happened with "Synology M2 volume" and "Synology HDD db" when I followed the post here

Thank you for the scripts :)

Originally created by @pitchea on GitHub (Jan 18, 2024). Original GitHub issue: https://github.com/007revad/Synology_enable_M2_card/issues/34 Between version v3.0.9 and v3.0.11 the EOL changed from LF to CRLF. When I ran the 'syno_enable_m2_card.sh' (v3.0.11) script on my Syno DS1621+ I got the following error: ``` /usr/bin/env: ‘bash\r’: No such file or directory ``` where the \r is a result of the CR from the Windows EOL encoding instead of the UNIX EOL encoding. Swapping it back to LF, the script works perfectly. v3.0.11: ![image](https://github.com/007revad/Synology_enable_M2_card/assets/26094611/f221eaee-9ae4-440d-a606-263ea8b8dd30) v3.0.9: ![image](https://github.com/007revad/Synology_enable_M2_card/assets/26094611/4fde3815-83a3-4a8f-b762-a7b41e22bf4e) Similar thing happened with "Synology M2 volume" and "Synology HDD db" when I followed the post [here](https://www.reddit.com/r/synology/comments/154l2gz/synology_enable_m2_card_enable_synology_m2_pcie/) Thank you for the scripts :)
kerem closed this issue 2026-03-07 19:11:23 +03:00
Author
Owner

@007revad commented on GitHub (Jan 19, 2024):

How did you download the scripts?

  • Did you download the script's release zip file or tar.gz file?
  • Or did you click on syno_enable_m2_card.sh then copy and paste the code into a text file?

Or did you view the script in Windows Notepad and click save?

<!-- gh-comment-id:1899431893 --> @007revad commented on GitHub (Jan 19, 2024): How did you download the scripts? - Did you download the script's release zip file or tar.gz file? - Or did you click on [syno_enable_m2_card.sh](https://github.com/007revad/Synology_enable_M2_card/blob/main/syno_enable_m2_card.sh) then copy and paste the code into a text file? Or did you view the script in Windows Notepad and click save?
Author
Owner

@007revad commented on GitHub (Jan 19, 2024):

By the way, which M.2 card do you have?

I assume the syn_enable_m2_card script worked to enable the M.2 card and the syno_enable_hdd_db script allowed you to use storage manager to create a volume on the NVMe drive(s) in the M.2 card?

<!-- gh-comment-id:1899435668 --> @007revad commented on GitHub (Jan 19, 2024): By the way, which M.2 card do you have? I assume the syn_enable_m2_card script worked to enable the M.2 card and the syno_enable_hdd_db script allowed you to use storage manager to create a volume on the NVMe drive(s) in the M.2 card?
Author
Owner

@pitchea commented on GitHub (Jan 19, 2024):

Ah, my apologies. After digging further, I realized it was my GitHub Desktop application when I cloned the repo and checked out the v3.0.11 tag. I never opened and viewed the file until I tried running it on my syno via ssh, but the git core.autocrlf was set to true on my Windows computer. Wiping out the file and git cloning it directly using git on Linux was fine.

I have the DS1621+ with an E10M20-T1 with two Samsung SSD 970 EVO Plus 2TB drives in the expansion card and another two in the built-in M.2 slots. They all work, thanks to your scripts. It appears the NIC also works. Cheers

<!-- gh-comment-id:1900593784 --> @pitchea commented on GitHub (Jan 19, 2024): Ah, my apologies. After digging further, I realized it was my GitHub Desktop application when I cloned the repo and checked out the v3.0.11 tag. I never opened and viewed the file until I tried running it on my syno via ssh, but the git core.autocrlf was set to true on my Windows computer. Wiping out the file and git cloning it directly using git on Linux was fine. I have the DS1621+ with an E10M20-T1 with two Samsung SSD 970 EVO Plus 2TB drives in the expansion card and another two in the built-in M.2 slots. They all work, thanks to your scripts. It appears the NIC also works. Cheers
Sign in to join this conversation.
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/Synology_enable_M2_card#3
No description provided.