show hdd under linux

English support forum

Moderators: Hacker, petermad, Stefan2, white

Post Reply
ismanpa
Junior Member
Junior Member
Posts: 31
Joined: 2005-02-17, 16:21 UTC

show hdd under linux

Post by *ismanpa »

Hello,

I have recently switched to Linux Mint. Krusader is very much like TC. However, I want to stick to what I know.

TC under Linux doesn't show the HDD the OS is installed on for security reasons I suppose. How can I see it?

Thank you!
User avatar
karlchen
Power Member
Power Member
Posts: 4605
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Re: show hdd under linux

Post by *karlchen »

Hello, ismanpa.
I have recently switched to Linux Mint. Krusader is very much like TC. However, I want to stick to what I know.
Be aware that T.C. on Linux runs under Wine.
Wine makes T.C. believe it were running in a Windows environment.
As a consequence T.C. will not be able to do all the things which it can do on a genuine Windows system. There are limits as you will find out.
TC under Linux doesn't show the HDD the OS is installed on for security reasons I suppose. How can I see it?
Why do you think so? T.C. runs on Wine, as I said above. Wine tries to present the Linux filesystems to T.C. like Windows would.
I.e. Wine presents a drive C: to T.C. This drive C: in reality is a symbolic link pointing to the folder ~/.wine/drive_c. This is the sub-foldertree where all the Windows applications will be installed which you run on Wine.
Wine presents a drive Z: to T.C. This drive Z: in reality is a symbolic link pointing to the mount point /. / in turn is the root file system of your Linux installation.
So T.C. will see the Linux filesystem as drive Z:.

Depending on your Wine configuration Wine may display some more drive letters. Note that each drive letter in reality will be a symbolic link pointing to some Linux folder.
You can find all existing (pseudo) drive letters in the folder ~/.wine/dosdevices.

Note:
~ is the brief way of pointing to your personal home folder. The fullname of the home folder will be /home/ismanpa, assuming that your loginname on Linux is ismanpa.

Cheers,
Karl
--
P.S.:
I am writing this message from a Linux Mint 13 system. T.C. 8.51a is running on Wine here as well. :wink:
ismanpa
Junior Member
Junior Member
Posts: 31
Joined: 2005-02-17, 16:21 UTC

Re: show hdd under linux

Post by *ismanpa »

Karl,

Thank you for the reply. it is very informative. I know some of the things, but still can;t find my HDD. Wine configuration tool doesn/t show dotted file although I have ticked the corresponding button and so, I am unable to add a drive. Any ideas?

Also, I cant run Windows programs from TC.

Regards,
George
karlchen wrote:Hello, ismanpa.
I have recently switched to Linux Mint. Krusader is very much like TC. However, I want to stick to what I know.
Be aware that T.C. on Linux runs under Wine.
Wine makes T.C. believe it were running in a Windows environment.
As a consequence T.C. will not be able to do all the things which it can do on a genuine Windows system. There are limits as you will find out.
TC under Linux doesn't show the HDD the OS is installed on for security reasons I suppose. How can I see it?
Why do you think so? T.C. runs on Wine, as I said above. Wine tries to present the Linux filesystems to T.C. like Windows would.
I.e. Wine presents a drive C: to T.C. This drive C: in reality is a symbolic link pointing to the folder ~/.wine/drive_c. This is the sub-foldertree where all the Windows applications will be installed which you run on Wine.
Wine presents a drive Z: to T.C. This drive Z: in reality is a symbolic link pointing to the mount point /. / in turn is the root file system of your Linux installation.
So T.C. will see the Linux filesystem as drive Z:.

Depending on your Wine configuration Wine may display some more drive letters. Note that each drive letter in reality will be a symbolic link pointing to some Linux folder.
You can find all existing (pseudo) drive letters in the folder ~/.wine/dosdevices.

Note:
~ is the brief way of pointing to your personal home folder. The fullname of the home folder will be /home/ismanpa, assuming that your loginname on Linux is ismanpa.

Cheers,
Karl
--
P.S.:
I am writing this message from a Linux Mint 13 system. T.C. 8.51a is running on Wine here as well. :wink:
ismanpa
Junior Member
Junior Member
Posts: 31
Joined: 2005-02-17, 16:21 UTC

found how

Post by *ismanpa »

Hello,

I have found out how to add a drive. Wine/Configure Wine/Drives/Add and /media/username and choose.
User avatar
karlchen
Power Member
Power Member
Posts: 4605
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

Hello, ismanpa.
still can't find my HDD.
Could this be a misunderstanding of what Total Commander displays on Windows as well?

On Windows Total Commander will display so-called drives, C:, D:, etc.
But although people often use the term disks and drives as synonyms, in fact they are not.

E.g. my notebook here has got one internal harddisk. But under Windows you will see 2 drive letters, C: and D:.
In fact, Windows drives are disk partitions.
So this notebook has got 1 harddisk with 2 disk partitions which Windows refers to as C: and D:

Partitions is what Linux Mint works with.
On Linux you do not call them drives and they do not have drive letters.
You call them disk partitions.
And they have got mount points.

A disk partition will have a filesystem on it. This filesystem may be ext4 (typical Linux filesystem) or FAT32 (Windows filesystem) or even NTFS (Windows filesystem).

As Linux Mint like any other Linux does not use drive letters, by default Wine will only present 2 pseudo drive letters to Total Commander, C: and Z:. Had explained so in my previous reply.

In addition, Total Commander will be able to see and display only filesystems which have been mounted (enabled).
And for Windows converts the tricky task will often be to find out the moint points of filesystems.
The command

Code: Select all

mount
will reveal them.

Example:

Code: Select all

$ mount | grep "^/dev/"
/dev/loop0 on / type ext4 (rw,errors=remount-ro)
/dev/sda2 on /host type fuseblk (rw,nosuid,nodev,relatime,user_id=0,group_id=0,allow_other,blksize=4096)
There are 2 disk devices which have a mounted filesystem.
One is /dev/loop0, mounted in folder /. This is my Linux Mint root filesystem.
The other one is /dev/sda2, mounted in folder /host. This is the second partition (sda2) of my harddisk.

What about the first partition, /dev/sda1? - It has currently not been mounted and is not accessible at this point in time.

By the way the whole harddisk is named /dev/sda. You will never see /dev/sda inside Total Commander on Linux Mint.

If you would like to get a graphical visualization of how Linux Mint looks at your harddisk, at partitions, filesystems and mount points, then launch the programme named "Drives" from the Linux Mint menu.
Linux_harddisk_illustrated.png - Linux_harddisk_illustrated2.png - Linux_harddisk_illustrated3.png
(These are screenshots of "Drives".)
Be careful what you do inside drives. You may inspect everything. But you should be careful not to change anything unless you are aware of the consequences.

Hope I have not managed to confuse you totally. :wink:

Cheers,
Karl
User avatar
karlchen
Power Member
Power Member
Posts: 4605
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

Hello, ismanpa.
Also, I cant run Windows programs from TC.
Provided the Windows programmes which you want to launch have been installed on the Linux Mint system through Wine like T.C. itself, it should be possible to launch them by double-clicking the executable files.
I have got only a very small number of Windows programmes that run on Linux Mint under Wine, Notepad2 and Imagine. They can be launched by T.C. - Notepad2 e.g. is the <F4>-editor of T.C.

Cheers,
Karl
ismanpa
Junior Member
Junior Member
Posts: 31
Joined: 2005-02-17, 16:21 UTC

Post by *ismanpa »

Hello Karl,

Thank you so much for your replies!

I have already learned what you explain. My misuse of terminology about executing programs. They do. I meant, for example. clicking on a pdf and opening it. I realised that there are no associations for such actions.

I really do miss TC which is my favourite programme.
User avatar
karlchen
Power Member
Power Member
Posts: 4605
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

Hello, ismanpa.

Actually, it can be done. I can double click on most common documents types, definitely .pdf files, inside Total Commander on Wine, and the associated genuine Linux programme will be launched and open the double-clicked file. :-)

Solution #1: the perfectionist's approach, but not really perfect

The starting point is Total Commander internal file type associations. - As the Windows file type assocations are missing, I use the Total Commander internal file type associations instead.

Total Commander does not launch the associated Linux programmes directly, as it would under Windows. Instead it launches always the same "wrapper script" (a Linux bash script), which does the actual work:
+ transform any Windows pathname into valid Linux pathnames
+ launch the associated Linux programme
+ pass the double clicked filename to that programme

There is a thread where every detail of this setup has been explained. But this thread is in German. I will give the link nonetheless.
Aus T.C. heraus Dokumente mit Linux-Programmen öffnen (Open documents in Linux programmes from T.C.)
Either the Google translator will be good enough and the translated post(s) can be understood.
Or I may have to translate it into English.


Solution #2: The Linux Mint Community Tutorial: simpler, but not perfect, either

Moreover, there is a simpler approach to achieving the same goal:
wine - how to setup Total Commander to launch correct (default) application for selected file
This is a Linux Mint Community tutorial.
This approach to achieving the goal makes use of and depends on "xdg-open" which is the Linux Mint / Ubuntu way of associating document file types and installed Linux programmes.


HTH,
Karl
Last edited by karlchen on 2015-02-06, 10:49 UTC, edited 2 times in total.
Hansl
Junior Member
Junior Member
Posts: 65
Joined: 2006-02-09, 21:15 UTC

Post by *Hansl »

I really do miss a Linux port of TC!
Like you, imanpa, I'm running Linux Mint and use TC in Wine since I haven't found another Commander par to TC. Wine has its limitations so some things are not possible with TC there (drag&drop for instance). For doing system management in Linux one needs another native Commander; mostly I use Gnome Commander for those tasks.

About drives: Wine does hide its own WINEPREFIX ~/.wine folder from the programs running in that WINEPREFIX to prevent circles. Instead, that folder is presented as C:\ . Any other “drive letters” you want to see in TC you have to set up in winecfg.

Since I came from Windows I still have some remains like a second physical hard drive for my data etc. Also I have shared network drives which are also accessed by other Windows users anf files containing links into those shared drives.

My solution was to mount those drives in my Linux system in the file system root as /D/, /R/, /S/ etc., make symbolic links like /D:/, /R:/ to them (because some Linux and Java programs don't like colons ‘:’ in a path) and then mount these mount points in Wine as D:\ etc. exactly like the network drives in the Windows systems. This way, I can use TC's tree and fast cd functions, and links like file:///S:/somepath/somefile.pdf work the same in Linux and Windows systems and programs.

About file associations: You can have them in TC in wine, too. But it is a bit of a pain to set them up for Linux apps. There are some different ways to do this you can find in this board. My way is as follows:

I wrote a script /usr/local/bin/runlinuxapp :

Code: Select all

#!/bin/bash
"$1" "`echo "$2" | sed -f /usr/local/bin/sedcmd_wp2up`"
where /usr/local/bin/sedcmd_wp2up is

Code: Select all

s%\\%\/%g
s%^%/%
Then I set up TC's Internal Associations for every file type I want like

Code: Select all

file type:  *.pdf  
open:  /usr/local/bin/runlinuxapp "atril" "%1"  
which runs Linux's pdf viewer from TC (when the mounts are set up like described above). Works fine for me.

For Windows apps (I like IrfanView, for instance) installed in the same WINEPREFIX as TC you can use TC's Associations like in Windows.
Some problematic Windows apps are better set up in separate WINEPREFIXes.

Again: I REALLY DO MISS A LINUX PORT OF TC!

Hans
ismanpa
Junior Member
Junior Member
Posts: 31
Joined: 2005-02-17, 16:21 UTC

Post by *ismanpa »

Karlchen and Hansf,

Thank you very much for your help. I do appreciate it indeed.

For the time being I have decided not to do techie things on LInux as I am not experienced; I will stick to native Linus ways of doing things.

I still feel annoyed when by habit press Enter of a file in TC and nothing happens :)

I will try Gnome Commander. I have found and started using a programme very similar to TC - Krusader.
Post Reply