Page 2 of 10 FirstFirst 1234 ... LastLast
Results 11 to 20 of 92

Thread: 11.2 partition isolation issue

  1. #11

    Default Re: 11.2 partition isolation issue

    First of all, dolphin doesn't care about /etc/fstab. If it would (as it should!), the solution would just be as easy as commenting out lines in that files. I have no name to qualify such "features" of those filemanagers ... maybe stupid, unacceptable, windowish, total nonsense. Twenty years ago we used to say that there was no decent filemanager for Unix (except maybe the Midnight Commander) ... and this hasn't changed. Dolphin, nautilus, Thunar and others are all pieces od the same kind of ... whatever you can figure out ... and all suffer from the Windows syndrom: making the user interface as friendly as possible and automounting, autoshowing, autoKISSing as many things as possible.

    It is not limited to filemanagers though but also affect open/save dialogs of any program using more or less directly the hal and udev daemons. In the case of dolphin it appears to be - still - a hal issue. The solution suggested by jdmcdaniel3 in post #3 or a similar one involving user defined udev rules should in theory (or would eventually) work. Unfortunately it does not as today because too many programs still rely on the hal daemon.

    An appropriate hal policy might help in some cases - although I have read people complainig that it didn't work for them ...

    Here's a screenshot of what I would 'normally' see in dolphin without the help of some extra hal policies - I took a screenshot of taking a screenshot because it was just hilarious. Where should I save this file?



    Now here's which partitions dolphin shows after
    • closing it
    • writing the file /etc/hal/fdi/policy/preferences.fdi with the following content:
      Code:
      <?xml version="1.0" encoding="UTF-8"?> <!-- -*- SGML -*- -->
      <deviceinfo version="0.2">
      <device>
          <!-- hide ufs partitions -->
          <match key="volume.fstype" string="ufs">
              <merge key="volume.ignore" type="bool">true</merge>
          </match>
      </device>
      </deviceinfo>
    • restarting the hal daemon:
      Code:
      service haldaemeon restart
    • finally reopening dophin




    This policy made dolphin ignore all these ufs partitions. Again, it has nothing to do with /etc/fstab, the end of which you can see on that picture too.

    Now, as it doesn't still look clean enough, let's hide some other non openSUSE Linux partitions (logically in this example, FED means Fedora, UBU means UBUNTU, DEB means Debian and GEN means Gentoo). This can be achieved with the following /etc/hal/fdi/policy/preferences.fdi:

    Code:
    <?xml version="1.0" encoding="UTF-8"?> <!-- -*- SGML -*- -->
    
    <deviceinfo version="0.2">
    <device>
         <!-- hide ufs partitions -->
        <match key="volume.fstype" string="ufs">
            <merge key="volume.ignore" type="bool">true</merge>
        </match>
        <!-- hide Debian partitions -->
        <match key="volume.label" string_outof="DEB_ROOT;DEB_USR;DEB_VAR;DEB_LOCAL">
          <merge key="volume.ignore" type="bool">true</merge>
        </match>
        <!-- hide Ubuntu partitions -->
        <match key="volume.label" string_outof="UBU_ROOT;UBU_USR;UBU_VAR;UBU_LOCAL">
          <merge key="volume.ignore" type="bool">true</merge>
        </match>
        <!-- hide Fedora partitions -->
        <match key="volume.label" string_outof="FED_ROOT;FED_USR;FED_VAR;FED_LOCAL">
          <merge key="volume.ignore" type="bool">true</merge>
        </match>
        <!-- hide Gentoo partitions -->
        <match key="volume.label" string_outof="GEN_ROOT;GEN_USR;GEN_VAR;GEN_LOCAL">
          <merge key="volume.ignore" type="bool">true</merge>
        </match>
    </device>
    </deviceinfo>
    Now there are all gone from dolphin's left pane. But to illustrate that it has nothing to do with /etc/fstab and whatever partitions are really mounted, I also mounted my Fedora partitions, that I could of course browse with dolphin (if ever I would happend to use it - chances are low though.)


  2. #12
    Join Date
    Mar 2010
    Location
    Austin - Texas
    Posts
    10,140
    Blog Entries
    48

    Smile Re: 11.2 partition isolation issue

    Your descriptions and solutions are outstanding as usual please_try_again. I must say that I am not sure you really need a color monitor though. A green filter over the front might do the same thing. Back in the olden days we used to have green screen monitors, that could almost look the same. Ah, just joshin you please_try_again.

    Thank You,
    My Blog: https://forums.opensuse.org/blogs/jdmcdaniel3/

    Software efficiency halves every 18 months, thus compensating for Moore's Law

    Its James again from Austin, Texas

  3. #13
    Join Date
    Jun 2008
    Location
    Netherlands
    Posts
    25,124

    Default Re: 11.2 partition isolation issue

    @please_try_again.

    Excelent illustration!
    Now I never thought that Dolphin looked at /etc/fstab. I mentioned the commented out entry there only as a clarification of it's existence (I hate obfuscating computer output when showing it here, in general it will often lead to hiding the problem that must be found). Then Carlos pointed to the fact that noauto had a similar (but for me not the same) effect of an entry not being used at boot. It was (and I think Carlos will admit this) more or less off topic and realy leading away from the subject.

    I am realy pleased by your:
    I have no name to qualify such "features" of those filemanagers ... maybe stupid, unacceptable, windowish, total nonsense. Twenty years ago we used to say that there was no decent filemanager for Unix (except maybe the Midnight Commander) ... and this hasn't changed. Dolphin, nautilus, Thunar and others are all pieces od the same kind of ... whatever you can figure out ... and all suffer from the Windows syndrom: making the user interface as friendly as possible and automounting, autoshowing, autoKISSing as many things as possible.
    It expresses my feelings very good. I tried to say something similar above:
    In fact I am not convinced that I understand the function of the panel called Places/Locations in Dolphin (where this not available partition is shown).
    Partitions must not be shown by an end-user tool to an end-user. The system manager/administrator has configured the syystem to mount them (or not) at a proper place end the end-user walks through the directory tree and wil cross the partition boundaries without knowing. That is where an Operating System is for: hiding away the hardware from the user.
    Henk van Velden

  4. #14
    Join Date
    Jun 2008
    Location
    Netherlands
    Posts
    25,124

    Default Re: 11.2 partition isolation issue

    And to please_try_again's solution. While it works without doubt, I think it is no practical solution. Everytime that I on some system create/change/remove a partition that is not to be mounted at normal day to day running, I have to create/change/remove such a policy file. And what is done then? I assume that even no device special files are created or am I wrong here? When no device spcial files are created this is a nono. The system manager must be able to do something with those partitions, think of a quick mount - look at a 10.3 config file - unmount sequence.

    No the error (design error, no doubt advertised as a feature) is in Dolphin. And I have given up on these sorts of things ever being handled in a Unix/Linux way. Were it not for the OP's start of this thread, I wouldn't even have posted about it.
    Henk van Velden

  5. #15

    Default Re: 11.2 partition isolation issue

    Quote Originally Posted by hcvv View Post
    And to please_try_again's solution. While it works without doubt, I think it is no practical solution. Everytime that I on some system create/change/remove a partition that is not to be mounted at normal day to day running, I have to create/change/remove such a policy file.
    Well, against such "features", there is no solution but only more or less clever and efficient workarounds. After having a closer look at hal specs, I finally wrote a more generic policy, which seems to work fine under dolphin (which definitely still uses hal) but has no effect on nautilus (which probably needs a udev rule). It is intended to hide any not mounted partition. In fact, it just hides all partitions on non removable disks that have not to appear in a filemanager. The user needs to see directories and not hard disk partitions. (Notice that HAL actually means Hardware Abstraction Layer!)

    The /etc/hal/fdi/policy/preferences.fdi below should work as long as dolphin uses hal (probably not very long).

    Code:
    <?xml version="1.0" encoding="UTF-8"?> <!-- -*- SGML -*- -->
    <deviceinfo version="0.2">
    <device>
      <!-- hide not mounted partitions on non removable disks -->
      <match key="@info.parent:storage.removable" bool="false">
        <match key="volume.is_partition" bool="true">
          <match key="volume.is_mounted" bool="false">
            <merge key="volume.ignore" type="bool">true</merge>
          </match>
        </match>
      </match>
    </device>
    </deviceinfo>

  6. #16
    Join Date
    Jun 2008
    Location
    Netherlands
    Posts
    25,124

    Default Re: 11.2 partition isolation issue

    I understand the logic of the match rules. But may I ask what it does with the answer? If I understand correctly, it sets volume.ignore to true. But where is this stored and who (besides Dophin interpretes this?

    BTW about the test on volume.is_mounted. I see that Dokphin does NOT show mounted partitions in Places. That is, on my system, it shows / (with something that translates as Main Folder ), but I have a separate /home which is not shown.
    This gives me the idea that the test about being mounted can be omitted.

    And that panel Places also show somehing like Network??? Should that look if my eth0 is up???????
    Henk van Velden

  7. #17
    Carlos E. R. NNTP User

    Default Re: 11.2 partition isolation issue

    On 2010-12-26 23:36, hcvv wrote:
    >
    > robin_listas;2270472 Wrote:


    >> I define all partitions in fstab, and put those that should not be
    >> mounted
    >> as "noauto".


    > Well, putting a # before the line is easier then adding the noauto.


    No, it doesn't. A line commented out does not exist, for all effects. I want to inform the system
    that I don't want the partition on boot, but that I may want to do it myself, manually.

    > But I doubt that using noauto will teach Dolphin to behave


    It does tell nautilus to behave. I know because I reported those problems in Bugzilla and were
    corrected through the years: in gnome listed no auto partitions are not mounted and not shown. At
    least in my computer.

    I do not know how dolphin behaves in that situation, I just assumed it would.

    --
    Cheers / Saludos,

    Carlos E. R.
    (from 11.2 x86_64 "Emerald" GM (Minas Tirith))

  8. #18
    Join Date
    Jun 2008
    Location
    Netherlands
    Posts
    25,124

    Default Re: 11.2 partition isolation issue

    Quote Originally Posted by Carlos E. R. View Post
    On 2010-12-26 23:36, hcvv wrote:
    >
    > robin_listas;2270472 Wrote:


    >> I define all partitions in fstab, and put those that should not be
    >> mounted
    >> as "noauto".


    > Well, putting a # before the line is easier then adding the noauto.


    No, it doesn't. A line commented out does not exist, for all effects. I want to inform the system
    that I don't want the partition on boot, but that I may want to do it myself, manually.

    > But I doubt that using noauto will teach Dolphin to behave


    It does tell nautilus to behave. I know because I reported those problems in Bugzilla and were
    corrected through the years: in gnome listed no auto partitions are not mounted and not shown. At
    least in my computer.

    I do not know how dolphin behaves in that situation, I just assumed it would.

    --
    Cheers / Saludos,

    Carlos E. R.
    (from 11.2 x86_64 "Emerald" GM (Minas Tirith))
    I am very well aware about the difference between commenting out and usiing the noauto parameter. And when I comment it out, I want the system not to interprete it at all. I do not give the System Manager then the opportunity to mount it in an easy way because I want it like that. I keep it there only as a reminder to me (not to the system) how I used it last time. I am sorry that I made the little joke about the number of keys to type instead of pointing out that I choose delibratly between the several possibilities available.

    The fact that several of these "file manager" tools handle these unmounted partitions different makes the situation even worse. One looks to the partitions available (using something like fdisk -l or HAL), the next looks in the fstab without looking at the the noauto. the third looks at the fstab and ignores the noaouto ones (even when they are mounted by hand or not?) and another one looks at what is mounted. It is a mess.
    Henk van Velden

  9. #19

    Default Re: 11.2 partition isolation issue

    Quote Originally Posted by hcvv View Post
    I understand the logic of the match rules. But may I ask what it does with the answer? If I understand correctly, it sets volume.ignore to true. But where is this stored and who (besides Dophin interpretes this?
    Yes, it sets volume.ignore to true. The value is stored in the hal properties of this volume and passed to the applications (Dolphin among others) through the message bus. That's how (actually the hal way) you would hide partitions from filemanagers using hal.

    Quote Originally Posted by hcvv View Post
    BTW about the test on volume.is_mounted. I see that Dokphin does NOT show mounted partitions in Places. That is, on my system, it shows / (with something that translates as Main Folder ), but I have a separate /home which is not shown.This gives me the idea that the test about being mounted can be omitted.
    That's right. This match rule doesn't add anything. So the following policy does it too:

    Code:
    <?xml version="1.0" encoding="UTF-8"?> <!-- -*- SGML -*- -->
    <deviceinfo version="0.2">
    <device>
            <!-- hide not mounted partitions on non removable disks -->
            <match key="@info.parent:storage.removable" bool="false">
                    <match key="volume.is_partition" bool="true">
                            <merge key="volume.ignore" type="bool">true</merge>
                    </match>
            </match>
    </device>
    </deviceinfo>
    Quote Originally Posted by hcvv View Post
    And that panel Places also show somehing like Network??? Should that look if my eth0 is up???????
    Nope. It's not about your nic. I don't think hal can tell if it's up as it is not in the hardware layer, but it stores the MAC address:

    Code:
    for nic in $(lshal -s | grep '^net'  | sed '/loopback/d;/00_27_00_00/d;s|^|/org/freedesktop/Hal/devices/|') ; do
    	echo $(hal-get-property --udi $nic --key net.interface) ":" $(hal-get-property --udi $nic --key net.address) 
    done
    Actually I wanted to skip hal and wait until it dies. I hid my Unix partitions with a volume.fstype match rule. But this thread reminds me how annoying it can be to see partitions anywhere around and finally inspired me a script to query the hal daemon about partitions properties : Displaying partitions infos from hal daemon

    The hal specs are in the package hal-doc.

  10. #20
    Join Date
    Jun 2008
    Location
    Netherlands
    Posts
    25,124

    Default Re: 11.2 partition isolation issue

    Well, you have realy ventured deep into HAL.

    I am afraid that even when HAL disappears, this behaviour of showing the wrong things in File managers and the like will continue, because the designers of these software tools took the decission that it is a feature to show these partitions. Thus they will find ways to continue this in spite of HAL disappearing.

    To the OP @nospam999 (if (s)he is still following this thread): It seems that you have some supporters in your idea that these partitions should not be shown to end-users. I am however afraid that the Windows way of having things has crept to much into the minds of those who make tools like Dolphin and thus there is almost no chance to have this changed.

    You have also seen that there are ways to get what you want, but they keep your constant attention to keep things up-to-date and will most certainly have to be changed in future levels of the tools as they adapt their non-features to new ways of working.
    Henk van Velden

Page 2 of 10 FirstFirst 1234 ... LastLast

Posting Permissions

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