Differences
This shows you the differences between the selected revisions of the page.
ui_login_scp 2011-11-01 | ui_login_scp 2023-05-24 (current) | ||
Line 1: | Line 1: | ||
- | ====== SCP/Shell Tab (Login Dialog) ====== | + | ====== The SCP/Shell Page (Advanced Site Settings dialog) ====== |
- | //SCP/Shell tab// allows user to configure shell specific options. Mostly it helps WinSCP to modify remote environment to match its [[requirements#scp_requirements|requirements]]. The options are mainly used when working with [[scp|SCP protocol]]. Even if you are using [[sftp|SFTP protocol]], some of the options are made available for you, in case you are using some feature that require [[shell_session|separate shell session]]. ((When [[ui_login_sftp#protocol_options|fallback]] to [[scp|SCP protocol]] occurs, all options on the tab, including the disabled ones, are used. In case you need to modify some of the disabled options, make sure you explicitly select SCP protocol on the [[ui_login_session|Session tab]].)) | + | The //SCP/Shell page// on the [[ui_login_advanced|Advanced Site Settings dialog]] allows user to configure shell specific options. Mostly it helps WinSCP to modify remote environment to match its [[requirements#scp|requirements]]. The options are mainly used when working with [[scp|SCP protocol]]. Even if you are using [[sftp|SFTP protocol]], some of the options are made available for you, in case you are using some feature that require [[shell_session|separate shell session]]. ((When [[ui_login_sftp#protocol_options|fallback]] to [[scp|SCP protocol]] occurs, all options on the page, including the disabled ones, are used. In case you need to modify some of the disabled options, make sure you explicitly select SCP protocol on the [[ui_login|Login dialog]].)) |
&screenshotpict(login_scp) | &screenshotpict(login_scp) | ||
- | You need to check //Advanced options// to reveal the tab. | + | To reveal this page you need to select SCP on [[ui_login|Login dialog]]. Some of the options are available even for SFTP file protocol with page being labeled //Shell//. |
- | ===== Shell ===== | + | &toc_title_page_sections |
- | Use the //Shell// option to specify what shell WinSCP will use. The ''bash'' shell is recommended for working with WinSCP. If your default shell does not work with WinSCP, you can specify another shell. Typing the full path (e.g. ''/bin/bash'' or ''/usr/local/bin/bash'') is recommended. You can also make use of the option to alter session startup. For example to change the user after login (known as ''su'')·((See [[faq_su|FAQ]] for details.)). The command to start shell is interpreted by the SSH server, so the syntax can change with the server·((Typically it is regular shell command interpreted by the default shell of user.)). | + | |
+ | ===== [[shell]] Shell ===== | ||
+ | Use the //Shell// option to specify what shell WinSCP will use. The ''bash'' shell is recommended for working with WinSCP. If your default shell does not work with WinSCP, you can specify another shell. Typing the full path (e.g. ''/bin/bash'' or ''/usr/local/bin/bash'') is recommended. You can also make use of the option to alter session startup. For example to change the user after login (known as ''su'').((See [[faq_su|FAQ]] for details.)) The command to start shell is interpreted by the SSH server, so the syntax can change with the server.((Typically it is regular shell command interpreted by the default shell of user.)) | ||
WinSCP needs to know what environment variable contains exit code of the last command. By default it tries to autodetect that. However the autodetection can fail and also slows down login. You may specify the variable directly instead in //Return code variable// box. | WinSCP needs to know what environment variable contains exit code of the last command. By default it tries to autodetect that. However the autodetection can fail and also slows down login. You may specify the variable directly instead in //Return code variable// box. | ||
- | ===== Directory listing ===== | + | ===== [[directory_listing]] Directory listing ===== |
Use the //Listing command// to change shell command, WinSCP uses to list directory contents. Particularly if your shell does not print group name in directory listing by default, use ''ls -gla'' to enforce it. | Use the //Listing command// to change shell command, WinSCP uses to list directory contents. Particularly if your shell does not print group name in directory listing by default, use ''ls -gla'' to enforce it. | ||
- | When the //Ignore LS warnings// checkbox is ticked, WinSCP will ignore any error messages printed by the ''ls'' command as long as it produces some regular output too. It also makes WinSCP ignore exit code ''1'' of the command. The option was added primarily to override ''pagefile.sys'' access-error produced by [[&opensshwin|OpenSSH for Windows]] whenever root directory was opened. However it may be useful even in other situations. | + | When the //Ignore LS warnings// checkbox is ticked, WinSCP will ignore any error messages printed by the ''ls'' command as long as it produces some regular output too. It also makes WinSCP ignore exit code ''1'' of the command. |
The //Try to get full timestamp// makes WinSCP attempt to use ''%%--full-time%%'' option for ''ls'' command. It is particularly useful when you want to use some [[task_synchronize|synchronization]] command, for what you need precise timestamps. When it is ticked, WinSCP will add the option to the first ''ls'' command it issues. When the (first) command fails for whatever reason, WinSCP will stop using the option for the whole session. However in some cases WinSCP may fail to detect that the command failed. Then you need to disable the feature manually. | The //Try to get full timestamp// makes WinSCP attempt to use ''%%--full-time%%'' option for ''ls'' command. It is particularly useful when you want to use some [[task_synchronize|synchronization]] command, for what you need precise timestamps. When it is ticked, WinSCP will add the option to the first ''ls'' command it issues. When the (first) command fails for whatever reason, WinSCP will stop using the option for the whole session. However in some cases WinSCP may fail to detect that the command failed. Then you need to disable the feature manually. | ||
- | ===== Other Options ===== | + | ===== [[other_options]] Other Options ===== |
- | When //Lookup user groups// is ticked, WinSCP will use ''groups'' command on start-up to list groups the user belongs too. It will then offer the list on [[ui_properties|Properties dialog]] to allow user select the group instead of typing it. | + | When //Lookup user groups// is ticked, WinSCP will use ''groups'' command on start-up to list groups the user belongs too. It will then offer the list on [[ui_properties|Properties dialog]] to allow user select the group instead of typing it. Initially the checkbox is in undefined state, making WinSCP trying to list the groups, but suppressing any errors, if listing fails. |
During WinSCP start up, you may receive an error indicating a problem with the ''groups'' command. Untick the //Lookup user groups// box. More than likely your Linux environment doesn't have the ''groups'' command available. | During WinSCP start up, you may receive an error indicating a problem with the ''groups'' command. Untick the //Lookup user groups// box. More than likely your Linux environment doesn't have the ''groups'' command available. | ||
- | On start-up WinSCP will by default clear all aliases on commands it uses. This is done to avoid unexpected behaviour (e.g. alias ''rm'' to ''rm -i''). If there are no aliases influencing command behaviour, this feature can be disabled by unticking //Clear aliases//. This setting speeds up the login process. | + | On start-up WinSCP will by default clear all aliases on commands it uses. This is done to avoid unexpected behavior (e.g. alias ''rm'' to ''rm -i''). If there are no aliases influencing command behavior, this feature can be disabled by unticking //Clear aliases//. This setting speeds up the login process. |
- | WinSCP also clears set of environment variables know to influence the format of directory listing. These are: ''LANG'', ''LANGUAGE'', ''LC_CTYPE'', ''LC_COLLATE'', ''LC_MONETARY'', ''LC_NUMERIC'', ''LC_TIME'', ''LC_MESSAGES'' and ''LC_ALL''. If no such variable is set, untick //Clear national variables//. This setting speeds up the login process. | + | WinSCP also clears set of environment variables know to influence the format of directory listing. These are: ''LANG'', ''LANGUAGE'', ''LC_CTYPE'', ''LC_COLLATE'', ''LC_MONETARY'', ''LC_NUMERIC'', ''LC_TIME'', ''LC_MESSAGES'', ''LC_ALL'', ''BLOCK_SIZE'' and ''LS_BLOCK_SIZE''. If no such variable is set, untick //Clear national variables//. This setting speeds up the login process. |
WinSCP uses ''scp'' command to perform the transfer. On some SSH servers, particularly ssh.com, the ''scp'' may be a link to ''scp2'' command. The ''scp2'' is in fact SFTP server, that WinSCP cannot talk to in SCP mode. Check //Use scp2 with scp1 compat.// to make WinSCP try to force the ''scp'' command to use really the SCP protocol (using ''-1'' option). Note that if the server supports ''scp2'', it probably supports [[sftp|SFTP protocol]] too. | WinSCP uses ''scp'' command to perform the transfer. On some SSH servers, particularly ssh.com, the ''scp'' may be a link to ''scp2'' command. The ''scp2'' is in fact SFTP server, that WinSCP cannot talk to in SCP mode. Check //Use scp2 with scp1 compat.// to make WinSCP try to force the ''scp'' command to use really the SCP protocol (using ''-1'' option). Note that if the server supports ''scp2'', it probably supports [[sftp|SFTP protocol]] too. | ||
+ | |||
+ | ===== Further Reading ===== | ||
+ | |||
+ | Read more about [[ui_login|Login dialog]] and [[ui_login_advanced|Advanced Site Settings dialog]]. |