Find the answer to your Linux question:
Results 1 to 5 of 5
Morning. I've got several servers running RedHat4 ES, alongside several Windows 2003 servers with MS SQL on them. Is there a MS SQL Client for Linux so I can connect ...
  1. #1
    Just Joined!
    Join Date
    Jan 2010
    Posts
    3

    MS SQL Server Client

    Morning.

    I've got several servers running RedHat4 ES, alongside several Windows 2003 servers with MS SQL on them.

    Is there a MS SQL Client for Linux so I can connect to the SQL Server databases ?

    I'ev got Oracle running as well, and I can back these up from my linux boxes easily as there is a Linux ORacle client.
    I'd like to do the same with MS SQL, so I have one central location doing my database backups .

  2. #2
    Linux Guru Irithori's Avatar
    Join Date
    May 2009
    Location
    Munich
    Posts
    2,097
    You _could_ use tsql, which is part of the freetds package.

    But freetds is a quite dated project already and afaik, you can expect some charset hassle, features not supported etc.

    In the linux/bsd/windows network I work on, we use litespeed to create a local ms sql dump.
    Basically:
    - My backupsystem (bacula) starts a scheduled backup job on the ms sql machine
    - this job triggers an powershell script.
    - the powershell script is a wrapper for litespeed
    - after succesfull dump, the backup starts its filecopy to the backupmachine
    - if the dump should fail, no filecopy is done, the job is marked failed and a email is sent

    I know it takes more ressources than your approach.
    Namely:
    - creation of the local ms sql dump
    - space on the ms sql machines´ discs
    - reading of the local ms sql dump for copying over the net

    But the dumps are done by an actual and active software.
    And the latest of these dumps are already on the machine for quick restore.
    Last edited by Irithori; 01-20-2010 at 10:58 AM.
    You must always face the curtain with a bow.

  3. #3
    Just Joined!
    Join Date
    Jan 2010
    Posts
    3
    Thanks for this.

    So the backups are done on the Windows boxes themselves and then copied back to Linux .. ??
    Ok, will give this a go...

    I guess I either need to set Samba up on Linux, or use SSH and passwordless/key exchange so the passwords dont get prompted for.

  4. #4
    Linux Guru Irithori's Avatar
    Join Date
    May 2009
    Location
    Munich
    Posts
    2,097
    correct, the ms sql dump tool is on windows.

    As a first approach, you could trigger the ms sql dump via the task scheduler
    and let it write to a tmp directory.
    After succesful dump, move it to a backup directory.
    This way, there are only valid and consistent dumps in the backup directory.

    How you get the dumps to another machine then is a different task.
    But samba can be a way.


    Is your backup system capable of triggering scripts on the backupclients before backup?
    If yes, you can spare the steps "task scheduler" and "mv from tmp to backup directory"
    You must always face the curtain with a bow.

  5. #5
    Just Joined!
    Join Date
    Jan 2010
    Posts
    3
    Probably use Windows Scheduler to start the backup, and then ssh/sftp the backup/logfiles to the linux box.

    This sounds easiest !!!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
...