export/Import of stored session

Advertisement

Katwa
Guest

export/Import of stored session

Kindly provide option for import / Export of stored session, so that the stored session can be changed from one PC to another and to maintain a back up if a system crash

sam@katwa.com

Reply with quote

Advertisement

martin
Site Admin
martin avatar

my drive crashed before i made an INI file. Where is this data stored? the registry of my dead copy of windows?
Please read FAQ.

Reply with quote

pneema
Guest

Import Sessions from Previous Versions Ini?

Is there a way to import the stored sessions from a previous version if the previous version stored sessions in the .ini file instead of the registry ?

I've found where I can import PuTTy seessions, but what I've got is a copy of 4.04 on a thumbdrive and I've installed 4.06 using a full install on my laptop, just in case I don't have my thumbdrive plugged in for some strange reason.

I've set the full version of WinSCP to use stored sessions from the .ini file in the settings. I've copied and renamed the winscp404.ini to WinSCP.ini and restarted WinSCP, but it still sees only the test session that I created so that I could get to the advanced preferences.

I also put a copy of the standalone 4.06 on my thumbdrive, copied the winscp404.ini to winscp406.ini and that copy of WinSCP loads the .ini file fine and sees all the sessions just fine. I've even copied that .ini over to WinSCP.ini, replacing the previous version, thinking there might be a slight change in the .ini information.

The full version doesn't see the sessions in the .ini file.

I would prefer to have both the full and the copy on my thumbdrive to both work off the .ini files so that I can backup easier as well as making it easier to move updates back and forth.

I'm sure its something very simple that I'm missing, but I've checked the FAQ, but that only lists importing from PuTTy and nothing about upgrading from previous versions and pulling the session from the .ini file.

I've tried putting a copy of WinSCP.ini in the folder with WinSCP.exe as well as in the folder I specified WinSCP put temporary files, just in case it looked there as well.

I don't see anything under my Application Data/Local for WinSCP or I would try in there as well.

What am I missing ?

Reply with quote

Advertisement

martin
Site Admin
martin avatar
Joined:
Posts:
41,454
Location:
Prague, Czechia

Re: Import Sessions from Previous Versions Ini?

pneema wrote:

I've set the full version of WinSCP to use stored sessions from the .ini file in the settings. I've copied and renamed the winscp404.ini to WinSCP.ini and restarted WinSCP, but it still sees only the test session that I created so that I could get to the advanced preferences.
This looks like correct procedure. But just in case: Close all instances of WinSCP. Take your INI file from your thumbdrive and copy it over to WinSCP installation directory (typically c:\program files\winscp\) and rename it to winscp.ini (providing your executable name is winscp.exe). Then start winscp.exe. It should get the configuration from the INI file disregarding whether it was set to registry or INI file previously.

Reply with quote

pneema
Guest

Thank you :)

I think it was a "feature" of Vista.

If I deleted the WinSCP.ini file, copied the winscp406.ini over and renamed it WinSCP.ini, I could open the "fresh" WinSCP.ini in a text editor and it would show only the test account I had setup.

I finally got it to see the changes by opening both .ini files and copy and pasting the changes over.

Thank you for your patience. :)

Reply with quote

szsahin
Joined:
Posts:
1
Location:
Turkey

Export Session script

I am using WinSCP in my thumbdrive and storing sessions in .ini file. And when I want to migrate to a new version or copy sessions to another PC or backup my sessions data, I use a simple VBScript to transfer only stored sessions (nearly 130 sessions, it is painful to copy them by hand). It reads only stored sessions (including default session and username/passwords but without "stored ssh keys") and writes to a text file. Then I simply copy all text lines to new winscp.ini file. Of course with a little modification it can write directly to new winscp.ini and can be extended to extract information from registry as well. But for now it is enough for me and might be helpful for you...

This is the script I use:
<invalid hyperlink removed by admin>

Reply with quote

Guest

Re: Thank you :)

pneema wrote:

I think it was a "feature" of Vista.

If I deleted the WinSCP.ini file, copied the winscp406.ini over and renamed it WinSCP.ini, I could open the "fresh" WinSCP.ini in a text editor and it would show only the test account I had setup.

I finally got it to see the changes by opening both .ini files and copy and pasting the changes over.

Thank you for your patience. :)

I seem to be having a problem :)

I had the app on a desktop running windows XP.
I did an update, then an export of the ini file. I then copied it into the new directory of my laptop (running vista) however, i cant see any of the sessions that were exported from the desktop system.

I can see the sessions when i open the ini file, however, they dont seem to load into the winscp on the vista laptop
any help would be much appreciated

thanks
tanya

Reply with quote

Advertisement

martin
Site Admin
martin avatar
Joined:
Posts:
41,454
Location:
Prague, Czechia

Re: Thank you :)

Anonymous wrote:

I had the app on a desktop running windows XP.
I did an update, then an export of the ini file. I then copied it into the new directory of my laptop (running vista) however, i cant see any of the sessions that were exported from the desktop system.

I can see the sessions when i open the ini file, however, they dont seem to load into the winscp on the vista laptop
any help would be much appreciated
What version of WinSCP were you using before? Please note that the executable name was changed since 3.x, so you may need to rename the INI file to match your EXE name. Also long time ago, WinSCP stopped supporting sessions with certain special characters in their name, like slashes.

Reply with quote

automatix
Joined:
Posts:
1
Location:
Germany

import/add stored sessions

Hello Forum,

how can I import my stored sessions without I lose the old sessions. Also, there are two WinSCP installaions => two winscp.ini-files and I would like to add the sessions from the ini-A to the ini-B.

thx.

Reply with quote

martin
Site Admin
martin avatar
Joined:
Posts:
41,454
Location:
Prague, Czechia

Re: import/add stored sessions

automatix wrote:

how can I import my stored sessions without I lose the old sessions. Also, there are two WinSCP installaions => two winscp.ini-files and I would like to add the sessions from the ini-A to the ini-B.
You can open the INI file in any editor and copy the sections named [Sessions\...].

Reply with quote

PatriceH
Guest

Export/Import Session with V. 3.7.6 (build 306)

hello,

I've an old version installed and I would like to try export/import an another machine before upgrading to the last version 4.1.6.

There is not "Export" button in the Preference section in V 3.7.6.

So, I've installed the old version 3.7.6 an another computer with success. I've copied my C:\Program Files\WinSCP3\winscp3.ini to the new computer, then launched Winscp3.

I don't have any stored sessions ...

thanks for your help.

Reply with quote

Advertisement

martin
Site Admin
martin avatar
Joined:
Posts:
41,454
Location:
Prague, Czechia

Re: Export/Import Session with V. 3.7.6 (build 306)

PatriceH wrote:

I've an old version installed and I would like to try export/import an another machine before upgrading to the last version 4.1.6.

There is not "Export" button in the Preference section in V 3.7.6.

So, I've installed the old version 3.7.6 an another computer with success. I've copied my C:\Program Files\WinSCP3\winscp3.ini to the new computer, then launched Winscp3.

I don't have any stored sessions ...
Try to upgrade to 4.1.6 on the first computer and use the export function.

Reply with quote

Dan Tran
Guest

Copy WinSCP sessions from one machine to another

Open the Registry Editor, Search for "WinSCP". For me, it's under
HKEY_CURRENT_USER\Software\Martin Prikryl\WinSCP 2\
Right click on "Sessions", Export this to a .reg file
On your other machine, Open Registry Editor --> File --> Import to import the .reg file that you created above

Reply with quote

Darshan Mandhane
Guest

Solution to Export the Stored session in WinSCP

1. Go to WinSCP Preferences.
2. Other General options - Preferences.
3. Click on Storage
4. Make sure radio button of Configuration setting is set to INI file (WinSCP.ini)
5. Save and close WinSCP
6. Go to WinSCP installation directory and search for "WinSCP.ini"
7. Copy INI file to new computer where you want to import the previously stored sessions.


Bingo !! All Done..!! :D

Reply with quote

Advertisement

martin
Site Admin
martin avatar
Joined:
Posts:
41,454
Location:
Prague, Czechia

Re: Solution to Export the Stored session in WinSCP

Darshan Mandhane wrote:

1. Go to WinSCP Preferences.
2. Other General options - Preferences.
3. Click on Storage
4. Make sure radio button of Configuration setting is set to INI file (WinSCP.ini)
5. Save and close WinSCP
6. Go to WinSCP installation directory and search for "WinSCP.ini"
7. Copy INI file to new computer where you want to import the previously stored sessions.
As documented here:
https://winscp.net/eng/docs/config#export
you can export settings to an INI file without changing your configuration.

Reply with quote

Advertisement

You can post new topics in this forum