Can't get peacock to run

929 views
Skip to first unread message

aceb...@berkeley.edu

unread,
Jan 8, 2015, 3:58:54 PM1/8/15
to moose...@googlegroups.com
Using VM provided by you guys, I wanted to run the first example using peacock. Opened the bashrc file by typing kate ~/.bashrc

I looked for where peacock lives and then in terminal I did cd ~/projects/moose/gui and then I typed pwd which gave me this: /home/moose/projects/moose/gui

So in the .bashrc file at the bottom I placed the following: export PATH=/home/moose/projects/moose/gui:$PATH and saved it.

Then in terminal I typed: peacock

and it tells me that the command was not found. So I don't know what to do.

QUICK UPDATE: I closed and reopened the terminal. Went to cd ~/projects/moose/gui and typed peacock. Now it tells me Executable not found! Try specifying it using -e

Does this mean that peacock needs an input file? I thought that by typing peacock it would bring up a graphical interface.

Peterson, JW

unread,
Jan 8, 2015, 4:06:16 PM1/8/15
to moose-users
Yes, peacock needs to be run from a directory with a valid MOOSE executable, like moose_test-opt.  This is why we have you put peacock in your PATH, that way you can run peacock directly from your application directory.

--
John

aceb...@berkeley.edu

unread,
Jan 8, 2015, 4:18:11 PM1/8/15
to moose...@googlegroups.com
I still don't know what to do with this. Why isn't peacock running if allegedly I added it to the path?

Derek Gaston

unread,
Jan 8, 2015, 4:20:11 PM1/8/15
to moose-users
You can also run Peacock from any directory "underneath" a directory containing a MOOSE-based executable and it will automatically find the executable.

So, for instance you can go into ~/projects/moose/test/tests/kernels/simple_diffusion and run peacock from within there and it will automatically pick up your moose-test binary that you built in ~/projects/moose/test

As for why your PATH stuff isn't working I don't know.  What do you get if you do:

echo $PATH
ls /home/moose/projects/moose/gui

You can also always just run peacock directly like so:

/home/moose/projects/moose/gui/peacock

From wherever you are...

--
You received this message because you are subscribed to the Google Groups "moose-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to moose-users...@googlegroups.com.
Visit this group at http://groups.google.com/group/moose-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/moose-users/CANj%2BmwC8w38U5qLao%2Bd1CZq%3DOrh1B%3DC2O_hv5U%3Dxc%3DkmZ%2BKeMg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Andrs, David

unread,
Jan 8, 2015, 4:20:22 PM1/8/15
to moose...@googlegroups.com
Try:
cd ~/projects/moose/test
make
peacock

--
David

--
You received this message because you are subscribed to the Google Groups "moose-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to moose-users...@googlegroups.com.
Visit this group at http://groups.google.com/group/moose-users.

Peterson, JW

unread,
Jan 8, 2015, 4:24:51 PM1/8/15
to moose-users
On Thu, Jan 8, 2015 at 2:18 PM, <aceb...@berkeley.edu> wrote:
I still don't know what to do with this. Why isn't peacock running if allegedly I added it to the path?

*peacock* itself is in your PATH, but peacock by itself doesn't do anything.  Therefore you need to either:

1.) Run peacock from a directory where a valid MOOSE executable is sitting (have you built MOOSE and the moose_test-opt executable yet?)
or 
2.) Run peacock from an arbitrary directory and specify "-e /path/to/valid/moose/exectuable"

where obviously the last bit depends on your particular system.
 
--
John

Andrew....@csiro.au

unread,
Jan 8, 2015, 4:31:03 PM1/8/15
to moose...@googlegroups.com

Hi aceballos,

 

I have never used peacock seriously, but hopefully this might clear up some confusion.  You have a peacock executable (called “peacock”), and your computer must know where that lives, so you need ~/projects/moose/gui in your PATH.  Secondly, you have a moose executable, which does the moose finite-element simulations, which peacock uses and which it must know about.  Various moose executables probably exist on your system, eg moose/test/moose_test-opt, or moose/modules/combined/modules-opt, or moose/your_application/your_application-opt, etc.   If you haven’t got those, you need to make them, eg, cd moose/modules ; make       You need to tell peacock which executable you want to use.  I believe you can do this by running peacock from the directory where the executable resides, or use the “-e” flag.

 

a

 

 

Ph: +61 7 3327 4497.  Fax: +61 7 3327 4666
Queensland Centre for Advanced Technologies
PO Box 883, Kenmore, Qld, 4069 
 

--

Alejandro Ceballos

unread,
Jan 8, 2015, 4:38:32 PM1/8/15
to moose-users
Derek: Here are the outputs from your suggestions:

[moose][~/projects/moose/gui]> echo $PATH
/home/moose/projects/moose/gui:/opt/moose/vtk/bin:/opt/moose/openmpi/openmpi-1.6.5/gcc-opt/bin:/opt/moose/autojump/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games


[moose][~/projects/moose/gui]> ls /home/moose/projects/moose/gui
clean_pyc.sh  gui             mesh_info  plug_ins   utils
doc           input_template  peacock    resources  vtk


[moose][~/projects/moose/gui]> /home/moose/projects/moose/gui/peacock

Executable not found!
Try specifying it using -e



David: Your suggestion did work. The peacock interface came up, I loaded the example and out came the solution!

Thank you guys! I truly appreciate your speedy response.


--
You received this message because you are subscribed to a topic in the Google Groups "moose-users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/moose-users/4znQZzISgYc/unsubscribe.
To unsubscribe from this group and all its topics, send an email to moose-users...@googlegroups.com.

Anil Kunwar

unread,
Dec 12, 2016, 11:36:55 PM12/12/16
to moose-users
Hi John,
In my previous experience, when i added the path of gui in the bashrc file of Ubuntu 14.04 as
export PATH=/home/username/moose_projects/moose/gui:$PATH



and then run peacock as:
$ peacock


,
peacock would load immediately.

Now, in my  moose installation (new) in Ubuntu 16.04, when i try to start peacock with this command, the following message occurs as log
/opt/moose/miniconda/lib/python2.7/site-packages/matplotlib/font_manager.py:273: UserWarning: Matplotlib is building the font cache using fc-list. This may take a moment.
  warnings
.warn('Matplotlib is building the font cache using fc-list. This may take a moment.')

Executable not found!
Try specifying it using -e



So, in order to load peacock, either
(i)  i need to jump into $HOME/moose_projects/moose/test whether moose executable is located and type
$ peacock

there,
 or
(ii) specify the path of moose-executable while calling peacock in accordance to the above log prompt as
$ peacock -e  $HOME/moose_projects/moose/test/./moose_test-opt.





For requirement of regular calling of peacock, i have created a file called peacockgui in my application folder (~/home/username/moose_projects/danphe/) and typed therein
#!/bin/bash
peacock -e  $HOME/moose_projects/moose/test/./moose_test-opt.


I have made it an executable using
$ chmod +x peacockgui



Then, i use an alias name callpeacock to show its path in bashrc file.
$ gedit ~/.bashrc




alias callpeacock='. /home/username/moose_projects/danphe/peacockgui'


So, i can open the terminal and type
$ callpeacock


to load the installed peacock in moose.


Note:
The alias name "callpeacock" is used different than the name "peacock" as  invoking peacock in terminal refers to the installed peacock of the moose and aliasname cannot be used the same.

Yours Sincerely,
Anil Kunwar
Message has been deleted

Anil Kunwar

unread,
Dec 13, 2016, 3:38:08 AM12/13/16
to moose-users
Hi John,
Thank you for your concise and complete information.
Since the moose-based application has also executable, the peacock can also be run from the directory of executable of moose-based application (./danphe-opt in my context):
1. I jump into the folder of danphe where its executable (./danphe-opt) resides:
$ cd ~/moose_projects/danphe/
$ peacock


The peacock loads with success.

or,
2 . To call peacock from anywhere, i create aliasname "danphepeacock".
 (a) Create a file with name "peacockwithdanphe" and type therein
#!/bin/bash
peacock
-e $HOME/moose_projects/danphe/./danphe-opt



(b) Make it an executable file
$ chmod +x peacockwithdanphe



(c) Open the bashrc file
$ gedit ~/.bashrc



(d) Create the alias danphepeacock
alias danphepeacock='. /home/username/moose_projects/danphe/peacockwithdanphe'



(e) Type the alias in new terminal
$ danphepeacock



Yours Sincerely,
Anil Kunwar

On Friday, January 9, 2015 at 5:24:51 AM UTC+8, jw.peterson wrote:
Reply all
Reply to author
Forward
0 new messages