Posts mit dem Label windows werden angezeigt. Alle Posts anzeigen
Posts mit dem Label windows werden angezeigt. Alle Posts anzeigen

2012-03-05

creating my mobile toolbox (for windows) I


I am somewhat tired to re-install the same set of software again and again, every time I (have to) switch to a new PC. Probably it's me, not the PCs, but it takes some tome to have the system setup, and me productive again.
Somehow it's like a craftsman has to setup a new labor space with new tools in every house they visit. But craftsmen are clever, they bring your tools with them - and take them away if not needed anymore. In best case they do not leave any traces (except the work done).
I try to mimic this approach: I'm creating my own toolbox. Mine is not made of leather or plastic, it's made of an USB-stick, portableapps.com and some additional modifications.

First I chose the programs available in portableapps app directory: Notepad++, Google Chrome, KeePass,  PuTTY and WinSCP. I tried to keep the list small, but you can make your own decisions,  of course.

Unfortunately I need some more tools: As a DBA, sometimes I not only like  to access the database servers, but the database directly. I did not find any proper tool in the app directory, therefore I decided to include Oracles SQL Developer into my toolbox and followed the Portable Apps Format Specification. It's not that complex it looks at first sign. Here my steps:

  1. create the proper directory structure:
    SQLDeveloperPortable
    + App
      + AppInfo
      + DefaultData
    + Data
    + Other
      + Help
        + Images
      + Source

  2. download SQL Developer and unzip it into the App folder

  3. in AppInfo create the file appinfo.ini:
    [Format]
    Type=PortableApps.comFormat
    Version=2.0
    
    [Details]
    Name=SQLDeveloper Portable
    AppID=SQLDeveloperPortable
    Publisher=^/\x
    Homepage=berxblog.blogspot.com/2012/03/creating-my-mobile-toolbox-for-windows.html
    Category=Utilities
    Description=Oracle SQL Developer is a graphical version of SQL*Plus that gives database developers a convenient way to perform basic tasks
    Language=Multilingual
    Trademarks=Oracle
    InstallType=
    
    [License]
    Shareable=false
    OpenSource=false
    Freeware=false
    CommercialUse=true
    EULAVersion=1
    
    [Version]
    PackageVersion=3.1.07.42
    DisplayVersion=3.1
    
    [SpecialPaths]
    Plugins=NONE
    
    [Dependencies]
    UsesJava=no
    UsesDotNetVersion=
    
    [Control]
    Icons=1
    Start=sqldeveloper.bat
    ExtractIcon=App\sqldeveloper\icon.png
    

  4. In SQLDeveloperPortable create the file sqldeveloper.bat:
    REM ^/\x
    SET IDE_USER_DIR=%~d0\PortableApps\SQLDeveloperPortable\Data
    start /b %~d0\PortableApps\SQLDEveloperPortable\App\sqldeveloper\sqldeveloper.exe
    By setting IDE_USER_DIR all configurations will be stored on the USB-stick, not on (changing) PCs.

  5. creating a proper icon for App\sqldeveloper\icon.png

That's it - works like a charm!



Next I prepared Xming for the portable world. X11 is still needed in the world of an Oracle DBA.
The steps where similar to those of SQL Developer, therefore I only describe the differences here:
As I don't want to extract the installer of Xming, I just let it install onto my PC into C:\Program Files. Then I copied the full structure C:\Program Files\Xming into XmingPortable\App.
Also in this case a bat file as a wrapper is needed, as Xming needs some parameters to go into tray without a window:
start /b %~d0\PortableApps\XmingPortable\App\Xming\Xming.exe :0 ‑clipboard ‑multiwindow



By these 2 examples you can see it's nice and easy to have the private toolbox at your hands all the time.
I do not provide the packages for any of these programs. First, I don't want to take care of any legal implications. Second, I have no interest in this kind of work. I just have no skills in doing so. period.

2009-03-02

'symbolic link' for Windows ODBC drivers

Maybe you know this situation: (nearly) everyone in your Company has local Admin grants on 'his' (and her) local PC. So they install everything they want, also ODBC-Drivers with any name on any local location.
No problem so far, but if they want to share something with an ODBC connection string, they are doomed. Everyone has another version in another ODBC-location.

What else than to 'fake' any ODBC name to any directory you want?

Here is my solution (I don't know, if it's supported. It just works for me!)

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\<INSERT_ODBC_NAME_HERE>]
"APILevel"="1"
"CPTimeout"="60"
"ConnectFunctions"="YYY"
"Driver"="C:\\PATH\\TO\\YOUR\\DRIVER\\SQORA32.DLL"
"DriverODBCVer"="03.51"
"FileUsage"="0"
"Setup"="C:\\PATH\\TO\\YOUR\\DRIVER\\SQORAS32.DLL"
"SQLLevel"="1"
Just use the Driver and Setup files from an existing ODBC-Source.
Might it work for you also ;-)

2008-12-31

Windows NTP client - allow large time offsets

During the christmas holidays, I 'm doing my own christmas ralley to meet a rather huge family. At these visits I'm often asked to solve some smal or great PC-Problems. Even I'm no PC-pro, I'm something like the one-eyed among blindes. Ad of course it makes more sense to solve problems onsite than remote using just the telephone.
One of the problems was an old laptop with an decrepit BIOS-battery. This led to an totally insane system date at every startup. Even with a proper system time and NTP-Server setup it never set the time correctly as the time offset was to large.
After some searching within the registry I changed under HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\Config the parameters MaxNegPhaseCorrection and MaxPosPhaseCorrection toFFFFFFFF, which is the maximum value (approx 136 years). Now at every connection, or at least at every manual time adjustment, the time is really set (and no boring error message is shown).

2008-07-29

TimeMachine for windows

I love my Mac, and I like TimeMachine as the best new feature (I use) from Leopard.
I also searched for such a solution for Windows (e.g. for my parents or my sisters laptop).
My search has an end, I found rsyncbackup.vbs from heise.de.
I know, it's not a solution, jus a script. but I'm sure, I can adapt it a little bit, so it would be useable for my family (e.g.: in startup-script, check if target-disk is available, etc.)
We will see...