FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Debian > Debian User

 
 
LinkBack Thread Tools
 
Old 12-02-2007, 01:03 AM
Mark Grieveson
 
Default volume mgmt w/o gnome

> If it is mass-storage, you just mount it with a command like "mount
> -t auto /dev/sda1 /media/usb" (mount point and device might be
> different). Or you can put a line in /etc/fstab :

> /dev/sda1 /media/usb auto noauto,users 0 0

> Then you could just say "mount /media/usb".

Thanks for the response. when I try this, it tells me:

mount: you must specify the filesystem type

> If it is not mass storage, gphoto2 is the basic command line program
> to use.

gphoto2 has never worked with this camera. It has simply been
automagically mounted (via gnome) as a storarge device.

Mark


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
 
Old 12-02-2007, 01:24 AM
Ron Johnson
 
Default volume mgmt w/o gnome

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 12/01/07 17:42, Mark Grieveson wrote:
> Hello. I use fluxbox most of the time. But, when I plug in my hp315
> photosmart camera, I rely upon gnome to find it, and automagically
> mount it for me. Is it possible to completely remove gnome, and just
> mount this camera (or other USB storage devices) myself? Or, and even
> better, find a utility that, sans gnome, can automagically mount the
> camera itself?

Presuming that you, as a fluxbox user who always has lots of xterms
open, log in at the console instead of the Eeeevil [xgk]dm:
- - Log into VT1 as root and run # tail -f /var/log/syslog
- - In VT2 log in as yourself and plug in the camera.
- - Flip back to VT1 and see which device it loads as (sda1, etc.)
- - run # blkid /dev/sdX1
- - Put in your /etc/fstab:
UUID="<whatever>" /media/camera vfat defaults,noauto 0 2

Obviously, /media/camera must exist... Then remove the camera and
plug it in again.

Now you should be able to type:
$ mount -v /media/camera
$ ls -aFl /media/camera
$ umount -v /media/camera

If that works, purge GNOME, and fire up fluxbox.

That same technique should work for any USB or Firewire external
storage device.

- --
Ron Johnson, Jr.
Jefferson LA USA

%SYSTEM-F-FISH, my hovercraft is full of eels
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFHUhdHS9HxQb37XmcRAkNaAKDGBaRcm6ahWV0kw4Y2n5 YKQqwC3ACfdR+y
8f1qo9jHJOLiKQF1iGePYAU=
=sE6m
-----END PGP SIGNATURE-----


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
 
Old 12-02-2007, 01:28 AM
Angus Auld
 
Default volume mgmt w/o gnome

--- Mark Grieveson <dg135@torfree.net> wrote:

> Hello. I use fluxbox most of the time. But, when I
> plug in my hp315
> photosmart camera, I rely upon gnome to find it, and
> automagically
> mount it for me. Is it possible to completely
> remove gnome, and just
> mount this camera (or other USB storage devices)
> myself? Or, and even
> better, find a utility that, sans gnome, can
> automagically mount the
> camera itself?
>
> Also, I use kmix for a volume control, because this
> seems the only
> application that provides a small speaker applet on
> the fluxbox panel
> to control sounds. I'd like to get rid of it, and
> the kde libs that
> accompany it. So, is there a fluxbox-specific
> volume control that sits
> nicely on the panel? (Preferably one that actually
> looks like a volume
> control, and not something gawd-awful looking?) If
> not, fine, I'll
> just use xmixer, or alsamixer, or something. Still,
> there really should
> be a something other than kmix, for a volume
> control, that can sit
> nicely on the fluxbox panel.
>
> Mark
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
Check out gkrellm and its various plugins. There is a
volume
control amongst them.
Should work w/fluxbox, I think.

Regards.

-- Angus

######Linux Laptop powered by Debian Linux######
###########Reg. Linux User #278931###########


__________________________________________________ __________________________________
Be a better sports nut! Let your teams follow you
with Yahoo Mobile. Try it now. http://mobile.yahoo.com/sports;_ylt=At9_qDKvtAbMuh1G1SQtBI7ntAcJ


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
 
Old 12-02-2007, 01:29 AM
"Kelly Clowers"
 
Default volume mgmt w/o gnome

On Dec 1, 2007 6:03 PM, Mark Grieveson <dg135@torfree.net> wrote:
> > If it is mass-storage, you just mount it with a command like "mount
> > -t auto /dev/sda1 /media/usb" (mount point and device might be
> > different). Or you can put a line in /etc/fstab :
>
> > /dev/sda1 /media/usb auto noauto,users 0 0
>
> > Then you could just say "mount /media/usb".
>
> Thanks for the response. when I try this, it tells me:
>
> mount: you must specify the filesystem type

Auto should work, but the FS should be vfat, so -

stand alone command:
mount -t vfat /dev/sda1 /media/usb
(-t means type; again, paths may be different)

or in fstab:
/dev/sda1/ /media/usb vfat noauto,users 0 0

...and then:
mount /media/usb

You can get more info with "man mount" and "man fstab"


Cheers,
Kelly


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
 
Old 12-02-2007, 03:54 AM
Dave Thayer
 
Default volume mgmt w/o gnome

On Sat, Dec 01, 2007 at 06:42:09PM -0500, Mark Grieveson wrote:
> Hello. I use fluxbox most of the time. But, when I plug in my hp315
> photosmart camera, I rely upon gnome to find it, and automagically
> mount it for me. Is it possible to completely remove gnome, and just
> mount this camera (or other USB storage devices) myself? Or, and even
> better, find a utility that, sans gnome, can automagically mount the
> camera itself?

Funny you should mention this, I've been working on this problem
myself lately. As a fluxboxer, I have been somewhat envious with the
ease with which the gnome/kde folk are able to use USB MSDs.

For some time my approach was to write a udev rule for each new device
to give it a consistant name, write an autofs map for that device, and
set up a link in /media to the autofs mount. That way I could just plug
in my drive, cd to /media/whatever, do my thing, cd out of
/media/whatever, wait a few seconds for the automount to time out, and
unplug the drive. This is really convenient to use, but a PITA to set
up each time I got a new USB toy. Plus, my /media was filling up with
rarely used symlinks.

I finally got fed up with this and came up with the following
solution. When I plug in a USB device, udev calls a script which
writes an autofs map for that device and then reloads autofs. While
writing this I found the --ghost option which makes the symlink
creation unneeded. The mountpoints are created in /media/auto and are
named after the devices volume label, or failing this the device's
model name, falling back on /media/auto/removble_drive. Subsequent
devices with the same name are named /media/auto/somename.1, and so on.

Anyway, with autofs installed I added this to /etc/auto.master:

---CUT HERE---
/media/auto /etc/auto.removable --timeout=2 --ghost
---CUT HERE---

I have these udev rules in /etc/udev/rules.d/002_local_automount.rules
[beware of word-wrap]

---CUT HERE---
# use -*- SH -*- mode to turn off wordwrap in jed
#Specifying ENV{ID_FS_USAGE}=="filesystem" doesn't work on add, test inside run cmd
BUS=="usb|ieee1394",SUBSYSTEM=="block",ACTION=="ad d", run+="/usr/local/bin/removable_drive_handler"

#Specifying BUS doesn't work on remove, but you're unlikely to remove anything besides usb or fW
SUBSYSTEM=="block",ACTION=="remove",ENV{ID_FS_USAG E}=="filesystem", run+="/usr/local/bin/removable_drive_handler"
---CUT HERE---

Finally, /usr/local/bin/removable_drive_handler :

---CUT HERE---
#! /bin/bash

vfat_mount_options="-fstype=auto,quiet,sync,nodev,nosuid,gid=floppy,dma sk=002,fmask=113,shortname=mixed"
unix_mount_options="-fstype=auto,sync,nodev,nosuid"
map_file="/etc/auto.removable"
default_mountpoint_name="removable_drive"
autofs_mount_dir="/media/auto"
autofs_pid_file="/var/run/autofs/_media_auto.pid"

#Clean out dead automounts, go through map file and remove any maps
#which refer to non-existant nodes in /dev
test "$ID_FS_USAGE" = "filesystem" || exit 0

case "$ACTION" in

"remove" )
# clean out stale maps and remove specified map
echo #Editing is futile, automatically generated at $(date) > $map_file.new
while read key options location
do
if [ "$location" != ":$DEVNAME" -a -e "${location##:}" ] #Remove colon to look for node
then
echo $key $options $location >> $map_file.new
fi
done < $map_file

mv $map_file.new $map_file
;;

"add" )
# Figure out name for mountpoint
if [ -n "ID_FS_LABEL_SAFE" ] #Prefer volume label as it's user controlled
then
mountpoint="$ID_FS_LABEL_SAFE"
elif [ -n "$ID_MODEL" ] #Next try device model name
then
mountpoint="$ID_MODEL"
else #Finally, use a default
mountpoint="$default_mountpoint_name"
fi

# If there's already a mountpoint with this name, try name.1, name.2 ...
if [ -e "$autofs_mount_dir/$mountpoint" ]
then
n=1
while [ -e "$autofs_mount_dir/$mountpoint.$n" ]
do
let "n += 1"
done
mountpoint=$mountpoint.$n
fi

# Add map for device using FS appropriate options
if [ "$ID_FS_TYPE" = "vfat" ]
then
echo "$mountpoint" $vfat_mount_options :$DEVNAME >> $map_file
else
echo "$mountpoint" $unix_mount_options :$DEVNAME >> $map_file
fi
;;
esac

# If kill doesn't work, use initscript
kill -HUP $(cat $autofs_pid_file) || /etc/init.d/autofs reload

---CUT HERE---

This is still very much a work in progress, so anybody with comments
or suggestions (keep it clean!) please feel free to chime in.

HTH

dt

--
Dave Thayer | Whenever you read a good book, it's like the
Denver, Colorado USA | author is right there, in the room talking to
dave@thayer-boyle.com | you, which is why I don't like to read
| good books. - Jack Handey "Deep Thoughts"


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
 
Old 12-02-2007, 11:03 AM
Micha Feigin
 
Default volume mgmt w/o gnome

On Sat, 1 Dec 2007 18:29:31 -0800
"Kelly Clowers" <kelly.clowers@gmail.com> wrote:

> On Dec 1, 2007 6:03 PM, Mark Grieveson <dg135@torfree.net> wrote:
> > > If it is mass-storage, you just mount it with a command like "mount
> > > -t auto /dev/sda1 /media/usb" (mount point and device might be
> > > different). Or you can put a line in /etc/fstab :
> >
> > > /dev/sda1 /media/usb auto noauto,users 0 0
> >
> > > Then you could just say "mount /media/usb".
> >
> > Thanks for the response. when I try this, it tells me:
> >
> > mount: you must specify the filesystem type
>

I think hal also does that. It's working on my xfce with thunar file manager,
no gnome. You probably need a file/desktop manager that can get hal
notifications though (it's either that or dbus, if you know which package does
this you can probably look into it's dependencies)

> Auto should work, but the FS should be vfat, so -
>
> stand alone command:
> mount -t vfat /dev/sda1 /media/usb
> (-t means type; again, paths may be different)
>
> or in fstab:
> /dev/sda1/ /media/usb vfat noauto,users 0 0
>
> ...and then:
> mount /media/usb
>
> You can get more info with "man mount" and "man fstab"
>
>
> Cheers,
> Kelly
>
>


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
 
Old 12-02-2007, 01:57 PM
"Matt Everingham"
 
Default volume mgmt w/o gnome

I know the conversation has gone way beyond this at this point (really, brilliant stuff), but I usually just "cheat" and use konqueror.* I use it for other tasks too (remote connections, etc.), so I don't worry about the memory usage.* I know this is a n00b answer, but thought I would throw it out there since the original question didn't specify CLI only.
 
Old 12-02-2007, 02:33 PM
Sjoerd Hiemstra
 
Default volume mgmt w/o gnome

Mark Grieveson wrote:
> Also, I use kmix for a volume control, because this seems the only
> application that provides a small speaker applet on the fluxbox panel
> to control sounds. I'd like to get rid of it, and the kde libs that
> accompany it. So, is there a fluxbox-specific volume control that
> sits nicely on the panel?

My findings are that when I start RealPlayer, its volume control acts
as a master volume control for everything.
It has always been like this, on several distros and all versions of
Debian. Don't know the reason why.


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
 
Old 12-02-2007, 04:17 PM
Mark Grieveson
 
Default volume mgmt w/o gnome

On Sun, 2 Dec 2007 03:29:52 +0000 (UTC)
debian-user-digest-request@lists.debian.org wrote:

> Auto should work, but the FS should be vfat, so -
>
> stand alone command:
> mount -t vfat /dev/sda1 /media/usb
> (-t means type; again, paths may be different)
>
> or in fstab:
> /dev/sda1/ /media/usb vfat noauto,users 0 0
>
> ...and then:
> mount /media/usb

Yes, changing "auto" to "vfat" worked. Thanks.

Mark


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
 
Old 12-08-2007, 05:08 PM
T o n g
 
Default volume mgmt w/o gnome

On Sat, 01 Dec 2007 21:54:13 -0700, Dave Thayer wrote:

> On Sat, Dec 01, 2007 at 06:42:09PM -0500, Mark Grieveson wrote:
>> Hello. I use fluxbox most of the time. But, when I plug in my hp315
>> photosmart camera, I rely upon gnome to find it, and automagically
>> mount it for me. Is it possible to completely remove gnome, and just
>> mount this camera (or other USB storage devices) myself? Or, and even
>> better, find a utility that, sans gnome, can automagically mount the
>> camera itself?
>
> Funny you should mention this, I've been working on this problem
> myself lately. As a fluxboxer, I have been somewhat envious with the
> ease with which the gnome/kde folk are able to use USB MSDs.
>
> For some time my approach was to . . . I finally got fed up with this and
> came up with the following solution. . .

Thank you Dave for insightful instructions.

So far I haven't notice any one mentioning pmount yet, which is what I
believe the right tool to use without rolling up you sleeves and get your
hands dirty.

This is the note that I collected,

Automounting
http://xpt.sourceforge.net/techdocs/nix/disk/pen/pen03-Automounting/index.html

All else notes on pmount
http://xpt.sourceforge.net/cgi-bin/search?P=pmount&DEFAULTOP=and&DB=default&FMT=query &xDB=default&xFILTERS=--A

I haven't tried it yet, since I'm a command line guy, and the
following command line has not bothered me yet:

sudo mount -o umask=113,dmask=002,uid=tong,gid=tong /dev/disk/by-id/usb-PENTAX_OptioT10-part1 /mnt/camera

See, no udev rules fiddling at all.

HTH

--
Tong (remove underscore(s) to reply)
http://xpt.sourceforge.net/techdocs/
http://xpt.sourceforge.net/tools/


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
 

Thread Tools




All times are GMT. The time now is 02:51 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org