wee_config utility (and others) won't run

744 views
Skip to first unread message

David Beach

unread,
Nov 3, 2018, 12:14:12 PM11/3/18
to weewx-user
I have a reliable weewx installation on a Raspberry Pi using a Vantage Vue. And it is still working well.

But, I disliked the scattered directories of the standard installation so I set up a new SD card with Raspian Stretch. I followed the setup.py installation instructions (with only a few minor detours!) I set it to Simulator and weewx seems to work fine in that mode. I can view the web page at /home/weewx/public_html/index.html with the 'fake' data streaming in.

However, when I try to run a utility, by typing "wee_config --help" for example, I get:

bash: wee_device: command not found

If I precede it with sudo, I get:

sudo: wee_config: command not found

Even if I change directories so that I am in the /home/weewx/bin directory and I can see the wee_config file just sitting there, I get the same result. I would like to be able to use wee_config so I can change the driver to my Vantage when I'm ready to switch.

I am no Linux or weewx expert. Is there some mystical permission or path I need to change? I hope that someone spots an obvious problem.

Thanks!

David

Thomas Keffer

unread,
Nov 3, 2018, 12:40:41 PM11/3/18
to weewx...@googlegroups.com
The shell scans a "path" to find an executable. By default, your current directory is not in the path. This is for security reasons: it prevents you from accidentally running something in your current directory that you may have forgotten about, or downloaded.

You must explicitly tell the shell that you know it's in your current directory. You do this by prepending './' to the executable file. So, it becomes

  cd /home/weewx/bin
  ./wee_config /home/weewx/weewx.conf --help

-tk

--
You received this message because you are subscribed to the Google Groups "weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

David Beach

unread,
Nov 3, 2018, 1:08:37 PM11/3/18
to weewx-user
Thanks so much. I was hoping it would be something fairly obvious to a Linux expert.

From the dark days of MS-DOS, I remember we could set 'paths' on start up so that you would not have to explicitly type in paths every time we issued a command. Is there something that I can set so that when I boot up and log in as user 'pi' (my home directory is /home/pi) I can run wee_config (or other utility) by just typing the file name - without the extra stuff every time? And could I avoid having to be in the /home/weewx/bin directory *every* time?

David

David Beach

unread,
Nov 3, 2018, 1:30:01 PM11/3/18
to weewx-user
By the way, free to point me to a simple tutorial on this if that would be easier for you than typing long instructions.

David

Thomas Keffer

unread,
Nov 3, 2018, 3:17:14 PM11/3/18
to weewx...@googlegroups.com

vince

unread,
Nov 3, 2018, 7:30:51 PM11/3/18
to weewx-user
On Saturday, November 3, 2018 at 10:30:01 AM UTC-7, David Beach wrote:
By the way, free to point me to a simple tutorial on this if that would be easier for you than typing long instructions.


Better yet - get yourself some real linux training (for free) rather than hunting and pecking as you battle through it the hard way.

Suggest the free Linux Foundation class on edx.org as one possibility.  Ignore the clickbait to pay $99 for a certificate.  The class is free and self-paced.

Liz

unread,
Nov 3, 2018, 8:28:01 PM11/3/18
to weewx...@googlegroups.com
On Sat, 3 Nov 2018 10:08:36 -0700 (PDT)
David Beach <david....@gmail.com> wrote:

> Thanks so much. I was hoping it would be something fairly obvious to
> a Linux expert.
>
> From the dark days of MS-DOS, I remember we could set 'paths' on
> start up so that you would not have to explicitly type in paths every
> time we issued a command. Is there something that I can set so that
> when I boot up and log in as user 'pi' (my home directory
> is /home/pi) I can run wee_config (or other utility) by just typing
> the file name - without the extra stuff every time? And could I avoid
> having to be in the /home/weewx/bin directory *every* time?
>
> David

Of course.
Add /home/weewx/bin to your path

here's a tutorial on how to do that.
www.techrepublic.com/article/how-to-add-directories-to-your-path-in-linux/

When you have added /home/weewx/bin to your path you won't need to
write the full path to run wee_config, nor need ./ prepended to the
command.

Be sure that user pi has the ability to run those commands or you will
need to run sudo wee_config

Liz

David Beach

unread,
Nov 3, 2018, 9:10:48 PM11/3/18
to weewx...@googlegroups.com
Thanks for that reference. With the TechRepublic article to get me started then the StackExchange one to tell me why they thought I should put the PATH reference into /.profile, I understood much better what was going on. And now my PATH has the correct addition. And even better, I also got nginx serving the weewx web page over my home network today, too. 

Thanks to everyone for taking the time to send me these helpful suggestions. I'm not sure if I'd call it a home run today - more like a base hit - bit certainly not a strike-out. All is well in Mudville tonight!

David

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

Steve C

unread,
Jan 14, 2023, 3:36:09 PM1/14/23
to weewx-user
Google may be our friend, and indeed, a Google search did to this old thread by searching for "wee_database: command not found". Specifically, this should be included: 
cd /home/weewx/bin
  ./wee_config /home/weewx/weewx.conf --help

 I see no way that I could add it to the WeeWX Utilities Guide, but it would be great if this were in the documentation.

I am sure I will get some heat for being grumpy, and I have been fighting errors all day, so I am frustrated for sure. How can I help update the documentation? The MySQL info was wrong in the main doc for example, Debian has switched to MariaDB as the default package some time ago. Which again, Google was helpful in pointing out, whereas the WeeWx doc is outdated.  https://www.weewx.com/docs/usersguide.htm#configuring_mysql  sudo apt install mysql-client is no longer correct.

vince

unread,
Jan 14, 2023, 4:17:38 PM1/14/23
to weewx-user
The 'command not found' problem has been documented in the FAQ for a long time.

Re: mariadb vs, mysqld, I know RaspiOS (Debian-ish) helps there and even tells you what the new name is...

# sudo apt install mysql-client
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Package mysql-client is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
However the following packages replace it:
  mariadb-client-10.0

But yes....there are a 'lot' of docs out there and some can be a bit dated.

FWIW -  the docs are all being actively updated to match the coming v5, so it's being worked and it'll be better.  Really.

Benedict

unread,
Aug 14, 2025, 8:19:10 AMAug 14
to weewx-user
Sorry guys, but this all seems to be deprecated info. There is no /home/weewx dir on my debian 12 install of weewx, and the wiki states that the executables would be under /usr/share/weewx, but they're not there. I only see some python stuff, and either way, this all means that none of the wee_* utilities commands work. I see no path to add for that, since these executables aren't there. Perhaps, also, since weewx and python have been installed using apt, not with pip (debian hates that), it may be a good idea to already *add* the required path during install, or at least prompt the user about where they are to be found.

~# wee_config --list-drivers
-bash: wee_config: command not found

michael.k...@gmx.at

unread,
Aug 14, 2025, 8:38:26 AMAug 14
to weewx-user
Sorry Benedict, but picking up a two-and-a-half year old discussion, from a time, WeeWX was a major release behind, and complaining about "deprecated info", is not comprehensible for me.

Did you check the docs for the current version (or at least for the version you are intending to install), especially the "Where to find things" Section? For 5.1 this is here: https://weewx.com/docs/5.1/usersguide/where/ 

If yes, and you are still thinking you are missing information, I'm sure there will be people here helping you out, preferable in a new post, to no mix it up with deprecated info.

Reply all
Reply to author
Forward
0 new messages