Defaulting a User Mountable (e.g USB /Thumb) Drive in CentOS With exec
Privileges
Language butchery by Mr Rich on 26.1.11 @ 11:21
I discovered this tip a few days ago while trying to get a USB drive (where I keep my timekeeping application) working. However I lost the URL that gathered this information from.
Symptoms
Resolution
Caveat: This is a pretty broadsword approach.
0 comments
Symptoms
- Drive mounts OK when attached (e. g.: plugged into USB)
- Cannot execute programs -- even as root.
- Does not show up in
/etc/fstab
- Shows up on
/etc/mtab
withnoexec
mounting options.
Resolution
Caveat: This is a pretty broadsword approach.
- When mounted, take a look at the details in
/etc/mtab
:cat /etc/mtab
- What you are looking for is the file system type and mounting options.
- Check out the details (including the options) in the
man
page formtab
.
- In the Gnome Configuration Editor:
- Find the file system ( /system/storage/default_options/...)
- Add the following as a high-priority item to the
mount_option
entry:exec
- Thus, your entry might look like this:
[exec,shortname=foo,uid=]
0 comments
Adding Programs to the 'Open With' Diaglog in Gnome
Language butchery by Mr Rich on ;@ 11:13
(Link in title is a complete dialog on the topic)
0 comments
- As superuser, edit:
/usr/share/applications/mimeinfo.cache
/etc/gnome_defaults.conf
or/etc/gnome/defaults.conf
- As normal user, edit the details in the
MimeType
section in~/.local/share/applications/[FOO-PROGRAM].desktop
0 comments
Sun Java Setup Notes on Centos x64
Language butchery by Mr Rich on 24.1.11 @ 09:58
Some notes for the next time I do this:
0 comments
- Find OpenJDK related packages. Take some notes as to what
alternatives
lists; you'll be setting this up later to point correctly to Sun Javayum list installed jre
yum list installed jdk
yum list installed gcj
ll /etc/alternatives/j*
- Uninstall OpenJDK related:
yum remove jre
yum remove /* other java related packages */
- Get the JDK for x_64 from Oracle ( http://www.java.com ); install as root as directed on site.
Take note of where Java installs to; you'll need it for re-pointingalternatives
! - Delete (if necessary) and make a soft link:
ln -s [location where Java installed] /usr/java/latest
- Re-point alternatives (as root):(... and anything else that needs to be re-pointed from the list step above)
/usr/sbin/alternatives --install /usr/bin/jar jar /usr/java/latest/bin/jar 1
/usr/sbin/alternatives --install /usr/bin/jarsigner jarsigner /usr/java/latest/bin/jarsigner 1
/usr/sbin/alternatives --install /etc/alternatives/java java /usr/java/latest/bin/java 1
/usr/sbin/alternatives --install /usr/bin/javac javac /usr/java/latest/bin/javac 1
/usr/sbin/alternatives --install /usr/bin/javadoc javadoc /usr/java/latest/bin/javadoc 1
/usr/sbin/alternatives --install /usr/bin/javah javah /usr/java/latest/bin/javah 1
/usr/sbin/alternatives --install /usr/bin/java_sdk java_sdk /usr/java/latest 1
/usr/sbin/alternatives --install /usr/bin/jre jre /usr/java/latest/jre/ 1
- Verify your setup:
java -version
javac -version
ls /etc/alternatives/j* - Setup the browser plugin for Firefox (these directions differ from those on Oracle's site):
(as root):cd /usr/lib64/mozilla/plugins
ln -s /usr/java/latest/jre/lib/amd64/libnpjp2.so . - If necessary, you may also need to setup the link to the Java plugin as the user:
(not super-user):cd ~/.mozilla/plugins
ln -s /usr/java/latest/jre/lib/amd64/libnpjp2.so .
- Site where found: http://labs.adobe.com/downloads/flashplayer10_square.html
- File desired:
flashplayer10_2_p3_64bit_linux_111710.tar.gz
Make sure you get the 64 bit version! The typical download location on Adobe's site doesn't list the 64 bit version! - As root, unpack the tarball into the mozilla plugin directory (where you created the link for the Java plugin above) and make it executable:
tar -zxvf flashplayer10_2_p3_64bit_linux_111710.tar.gz -C /usr/lib64/mozilla/plugins
chmod +x /usr/lib64/mozilla/plugins/libflashplayer.so
0 comments