Linker IT Software
Google
Web www.oraxcel.com
menubar-top-links menubar-top-rechts
Home Help Search Login
Welcome, Guest. Please Login.
SQL*XL: Database to Excel bridge litLIB: Excel power functions pack ExcelLock: Locking and securing your valuable Excel spreadsheets encOffice: Protect your Excel file easy and safe encOffice: Protect your Excel file easy and safe
Pages: 1
Microsoft Windows subsystem for UNIX: SFU : SUA (Read 27126 times)
Gerrit-Jan Linker
YaBB Administrator
*****




Posts: 75
Microsoft Windows subsystem for UNIX: SFU : SUA
06.08.10 at 13:39:50
 
Microsoft Windows subsystem for UNIX: SFU : SUA
 
Microsoft provides a subsystem for UNIX in Windows 7.  
 
Names:
SFU = Windows Services for UNIX  
SUA = Subsystem for UNIX-based Applications
Posix (is not the same as Interix)
 
You can enable the subsystem for unix (SFU) it in the windows program features (see Programs in the Control Panel). When downloading it you should download the AMD package and not the I package for 64bits windows:
Utilities and SDK for UNIX-based Applications_AMD64.exe  
 
http://www.microsoft.com/downloads/details.aspx?FamilyId=93FF2201-325E-487F-A398 -EFDE5758C47F&displaylang=en
 
See also:
Windows services for UNIX
http://en.wikipedia.org/wiki/Windows_Services_for_UNIX
Sua Community
http://www.suacommunity.com/SUA.aspx
Back to top
 
« Last Edit: 11.08.10 at 08:50:40 by Gerrit-Jan Linker »  

Gerrit-Jan Linker
Linker IT Software
Email WWW Gerrit-Jan Linker   IP Logged
Gerrit-Jan Linker
YaBB Administrator
*****




Posts: 75
Installing SUA
Reply #1 - 06.08.10 at 14:02:35
 
Installing SUA
 
Download the software from  
http://www.microsoft.com/downloads/details.aspx?FamilyId=93FF2201-325E-487F-A398 -EFDE5758C47F&displaylang=en  
 
Run the executable (self extracting zip file). Run the setup as a regular user (not as administrator). Chose custom install as the default install does not install the gnu utilities.
 
During the installation the following security settings can be made. Enable all 3 of them:
Enable Su to ToRoot behavior for SUA programs
Enable setuid behavior for SUA programs
Change the default behavior to case sensitive
 
To install more features you can download and install additional packages from http://www.suacommunity.com. For a complete toolset for x64, download this item despite it says that it is not for Windows 7 (actually none of the options are)
Download for SUA/Interix 6.0 64-bit [Only: Vista & W2K8]
 
To install this additional toolset open a command prompt (cmd) as administrator and run the downloaded .exe.
 
Installation instruction video
http://www.servedbyadbutler.com/redirect_alink.spark?ALID=3483&ID=147059
Back to top
 
« Last Edit: 07.08.10 at 11:12:25 by Gerrit-Jan Linker »  

Gerrit-Jan Linker
Linker IT Software
Email WWW Gerrit-Jan Linker   IP Logged
Gerrit-Jan Linker
YaBB Administrator
*****




Posts: 75
SFU : disable the loud beep on errors
Reply #2 - 07.08.10 at 20:46:24
 
SFU : disable the loud beep on errors
 
Very annoying, the shells beep very loudly when making an error. To switch it off I did not find a setting in posix. Instead I switched off the beep service in windows.  
 
See:
How to disable the internal PC speaker  
http://www.oraxcel.com/cgi-bin/yabb2/YaBB.pl?num=1154345613/0#0
Back to top
 
 

Gerrit-Jan Linker
Linker IT Software
Email WWW Gerrit-Jan Linker   IP Logged
Gerrit-Jan Linker
YaBB Administrator
*****




Posts: 75
UNIX commands in DOS
Reply #3 - 08.08.10 at 10:22:50
 
UNIX commands in DOS
 
After installing SFU, the windows subsystem for UNIX, I find that I can use the unix commands from a DOS box too. Start a command prompt: cmd. You can edit files with vi, remove files with rm and make directory listings with ls.  
 
What does not seem to work are ssh, scp, xclock... Just start a shell (ksh, csh) to use those.
Back to top
 
 

Gerrit-Jan Linker
Linker IT Software
Email WWW Gerrit-Jan Linker   IP Logged
Gerrit-Jan Linker
YaBB Administrator
*****




Posts: 75
SFU: Set the home directory
Reply #4 - 09.08.10 at 20:51:42
 
SFU: Set the home directory
 
To set the home directory in the Subsystem For Unix you need to start the computer management screen in windows 7. Just type it into the search box in the start menu of windows.
 
In system tools select: Local users and groups
Open users and double click the user account
Goto the profile tab
Enter the folder name in local path
 
You need to logout and log back into windows to activate the setting.
Back to top
 
 

Gerrit-Jan Linker
Linker IT Software
Email WWW Gerrit-Jan Linker   IP Logged
Gerrit-Jan Linker
YaBB Administrator
*****




Posts: 75
SFU: Working with terminals
Reply #5 - 10.08.10 at 23:57:59
 
SFU: Working with terminals
 
To work effectively with UNIX it is vital that terminal windows are working flawlessly.
 

  • Command box like terminals:
    I find there are two ways to work with terminal windows. The first is in a sort of command window similar to what is started when you run cmd.exe. To use this option just run ksh in the windows 7 search box.  
     
  • X windows terminals:
    The second option is to use the X windows xterminal with the command xterm. I have not found a way to run this from a shortcut (yet) without xterm closing immediately again. I start it from a terminal using the first method. Don't forget to run xterm in the background: xterm &
     
    If the x terminal does not have a history scrollbar you can use the -sb flag to show it. xterm -sb
     
    See also:
    xterm manual
    http://invisible-island.net/xterm/manpage/xterm.html
     
Back to top
 
« Last Edit: 11.08.10 at 08:44:56 by Gerrit-Jan Linker »  

Gerrit-Jan Linker
Linker IT Software
Email WWW Gerrit-Jan Linker   IP Logged
Gerrit-Jan Linker
YaBB Administrator
*****




Posts: 75
SFU: Working with the clipboard
Reply #6 - 11.08.10 at 08:39:42
 
SFU: Working with the clipboard
 
To use the clipboard in terminal windows is essential to effectively use UNIX in a windows environment or perhaps even in UNIX itself. When you use the command box type of terminal window you can click the window icon at the top left. You can mark and copy text and there is  a paste option too.
 
When using the xterm terminals I found that initially copy and paste did not work at all. I needed to start the XMing X windows server program with the -emulate3buttons 50 option to get it to work. In full, this is the shortcut I use to start XMing:
"C:\Program Files (x86)\Xming\Xming.exe" :0 -clipboard -multiwindow -emulate3buttons 50
Highlighting some text with the mouse is sufficient to copy it onto the clipboard. To paste press left and right mouse click simultaneously.
 
Back to top
 
 

Gerrit-Jan Linker
Linker IT Software
Email WWW Gerrit-Jan Linker   IP Logged
Gerrit-Jan Linker
YaBB Administrator
*****




Posts: 75
SFU: Working with the bash shell
Reply #7 - 29.08.10 at 13:11:16
 
SFU: Working with the bash shell
 
To be able to start a baash shell an extra batch file is needed. Copy the text below in a new file called bash.bat and place it in C:\Windows\SUA\common
 

C:\Windows\posix /u /c /usr/local/b
in/bash -l %1 %2 %3 %4 %5 %6 %7 %8 %9

 
 
You can now simply run bash (as SUA common is in the path) to start a bash shell.
The bash shell is handy when you want to have command history. Arrow down will scroll through the history of old commands.
Back to top
 
« Last Edit: 29.08.10 at 13:13:25 by Gerrit-Jan Linker »  

Gerrit-Jan Linker
Linker IT Software
Email WWW Gerrit-Jan Linker   IP Logged
Gerrit-Jan Linker
YaBB Administrator
*****




Posts: 75
SFU: ssh "could not resolve host name"
Reply #8 - 25.08.12 at 09:35:49
 
SFU: ssh "could not resolve host name"
 
I could ping to my host but not use ssh:
ping myserver  
ssh user@myserver
 
The first worked fine. The second failed with the message "Could not resolve host name myserver"
 
Add the ip address of myserver to the hosts file. See the following topic for more information:
http://www.oraxcel.com/cgi-bin/yabb2/YaBB.pl?num=1280958689
Back to top
 
 

Gerrit-Jan Linker
Linker IT Software
Email WWW Gerrit-Jan Linker   IP Logged
Pages: 1