LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 08-03-2012, 04:27 AM   #1
Reignfire
Member
 
Registered: Jun 2012
Posts: 56

Rep: Reputation: Disabled
bash: module: command not found


Hi,

I installed Environment Modules on my Debian ( with this tutorial: http://nickgeoghegan.net/linux/insta...onment-modules )

But i can't use the module command.

Code:
root@test:/etc/profile.d# module
-bash: module: command not found
Do i need to add something to $PATH or... ??
 
Old 08-03-2012, 04:33 AM   #2
pixellany
LQ Veteran
 
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Arch/XFCE
Posts: 17,802

Rep: Reputation: 738Reputation: 738Reputation: 738Reputation: 738Reputation: 738Reputation: 738Reputation: 738
First, find the executable file "module", and try running it with an absolute pathname.

eg:
find / -name "module"
suppose it shows up in /usr/bin: use the command:
/usr/bin/module

If that works, then add /usr/bin to your $PATH
 
Old 08-03-2012, 04:46 AM   #3
Reignfire
Member
 
Registered: Jun 2012
Posts: 56

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by pixellany View Post
First, find the executable file "module", and try running it with an absolute pathname.

eg:
find / -name "module"
suppose it shows up in /usr/bin: use the command:
/usr/bin/module

If that works, then add /usr/bin to your $PATH
I get the following:

Code:
root@test:/# find -name "module"
./var/software/modules-3.2.9/testsuite/modulefiles/conflict/module
./var/software/modules-3.2.9/testsuite/modulefiles/prereq/module
./var/software/modules-3.2.9/testsuite/modulefiles/module
./sys/bus/platform/drivers/dcdbas/module
./sys/bus/platform/drivers/pcspkr/module
./sys/bus/pci/drivers/ehci_hcd/module
./sys/bus/pci/drivers/bnx2/module
./sys/bus/pci/drivers/mpt2sas/module
./sys/bus/pci/drivers/ohci_hcd/module
./sys/bus/pci/drivers/ahci/module
./sys/bus/pci/drivers/piix4_smbus/module
./sys/bus/serio/drivers/serio_raw/module
./sys/bus/serio/drivers/psmouse/module
./sys/bus/usb/drivers/usbfs/module
./sys/bus/usb/drivers/hub/module
./sys/bus/usb/drivers/usb/module
./sys/bus/usb/drivers/hiddev/module
./sys/bus/usb/drivers/usbhid/module
./sys/bus/hid/drivers/generic-usb/module
./sys/bus/i2c/drivers/dummy/module
./sys/module
But none of the above makes it work.
 
Old 08-03-2012, 04:53 AM   #4
pixellany
LQ Veteran
 
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Arch/XFCE
Posts: 17,802

Rep: Reputation: 738Reputation: 738Reputation: 738Reputation: 738Reputation: 738Reputation: 738Reputation: 738
You missed the "/" in the command. As you show it, find will only search the current directory

Do this:
find / -name "module"
 
Old 08-03-2012, 04:55 AM   #5
Reignfire
Member
 
Registered: Jun 2012
Posts: 56

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by pixellany View Post
You missed the "/" in the command. As you show it, find will only search the current directory

Do this:
find / -name "module"
I was in the root directory so it gives the same result
 
Old 08-03-2012, 04:55 AM   #6
Nylex
LQ Addict
 
Registered: Jul 2003
Location: London, UK
Distribution: Slackware
Posts: 7,464

Rep: Reputation: Disabled
Quote:
Originally Posted by pixellany View Post
You missed the "/" in the command. As you show it, find will only search the current directory

Do this:
find / -name "module"
The OP's prompt shows that their current directory is /.
 
Old 08-03-2012, 05:06 AM   #7
pixellany
LQ Veteran
 
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Arch/XFCE
Posts: 17,802

Rep: Reputation: 738Reputation: 738Reputation: 738Reputation: 738Reputation: 738Reputation: 738Reputation: 738
Quote:
Originally Posted by Nylex View Post
The OP's prompt shows that their current directory is /.
touche!! (but I always specify the path when using find....)

In that case, maybe try:
find / -name "*module*"
OR
find / -name "*mod*"
 
Old 08-03-2012, 05:24 AM   #8
Reignfire
Member
 
Registered: Jun 2012
Posts: 56

Original Poster
Rep: Reputation: Disabled
In the directory were it was installed there's 'modulecmd' which does the same as "module" should do

Code:
root@test:/var/software/modules-3.2.9# modulecmd bash
cmdModule.c(166):ERROR:11: Usage is 'module command  [arguments ...] '

  Modules Release 3.2.9 2011-11-24 (Copyright GNU GPL v2 1991):

  Usage: module [ switches ] [ subcommand ] [subcommand-args ]

Switches:
        -H|--help               this usage info
        -V|--version            modules version & configuration options
...
 
Old 08-03-2012, 05:26 AM   #9
Nylex
LQ Addict
 
Registered: Jul 2003
Location: London, UK
Distribution: Slackware
Posts: 7,464

Rep: Reputation: Disabled
Then I guess "module" is usually a symbolic link to "modulecmd".
 
Old 08-03-2012, 12:38 PM   #10
pixellany
LQ Veteran
 
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Arch/XFCE
Posts: 17,802

Rep: Reputation: 738Reputation: 738Reputation: 738Reputation: 738Reputation: 738Reputation: 738Reputation: 738
Quote:
Originally Posted by Reignfire View Post
In the directory were it was installed there's 'modulecmd' which does the same as "module" should do
So--put that in $PATH---or just make a soft link to someplace that's already in $PATH
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
bash: command not found hamish Linux - Newbie 7 02-23-2011 05:28 PM
Installing perl module - sh: make: command not found Toadman Mandriva 2 12-28-2008 10:11 PM
Bash command not found Legolas327 Linux - Newbie 9 06-27-2007 08:44 PM
bash: rpm: command not found && sudo: alien: command not found Java_Code Ubuntu 7 07-28-2006 12:57 AM
-bash: cp: command not found johnlittlepeap Fedora 2 11-15-2004 09:52 AM


All times are GMT -5. The time now is 12:50 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration