General Tips/Tricks for Software configuration I find useful

Here I will add a list of tips and tricks that I have come across;

Changing default shell on lxplus

I recommend everyone RUN BASH, it's just more supported and isn't there for 'backwards compatability'

goto: https://cra.cern.ch/ login click on 'My Details' box under user info (left frame) find dropdown box next to shell and change that to bash hit the update button (bottom left) now when you login to lxplus your done

Fix Bash history on lxplus

Save this code as a script_name.sh and chmod +x script_name.sh and then run ./script_name.sh on an lxplus login.

Next time you login all the previous commands are easy to find smile

To search for that command or program option you can't quite remember:

cat ~/.bash_history | grep some-string

where some-string is what you want o pull out of your history.

#!/bin/bash
mkdir -p ~/backup-hist
cat .hist* >> .~/.bash_history
mv .hist* >> ~/backup-hist
for i in `seq 1 9`; do
        ln -sf ~/.bash_history "~/.history.lxplus00$i.cern.ch";
done
for i in `seq 10 99`; do
        ln -sf ~/.bash_history "~/.history.lxplus0$i.cern.ch";
done
for i in `seq 100 999`; do
        ln -sf ~/.bash_history "~/.history.lxplus$i.cern.ch";
done

-- RobCurrie - 05-Nov-2010

Edit | Attach | Watch | Print version | History: r2 < r1 | Backlinks | Raw View | WYSIWYG | More topic actions
Topic revision: r2 - 2010-11-08 - RobCurrie
 
    • Cern Search Icon Cern Search
    • TWiki Search Icon TWiki Search
    • Google Search Icon Google Search

    Main All webs login

This site is powered by the TWiki collaboration platform Powered by PerlCopyright &© 2008-2024 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
or Ideas, requests, problems regarding TWiki? use Discourse or Send feedback