chipKIT® Development Platform

Inspired by Arduino™

launch as root

Created Fri, 12 Apr 2013 13:30:27 +0000 by yaroslav kishchenko


yaroslav kishchenko

Fri, 12 Apr 2013 13:30:27 +0000

first time i installed MPIDE there were some java exceptions after i installed rxtx they dissapeare but only on regular user i still getting this exceptions when launch as root also some strange dialog apeare and asks for folder for scratches is it posisble to launch MPIDE from root and why it behaves so diferently


majenko

Fri, 12 Apr 2013 16:45:20 +0000

Should work fine as root. Mine does ;)

What is the exception you get, and what line number? Can you post the stack trace?


yaroslav kishchenko

Fri, 12 Apr 2013 16:56:40 +0000

here

http://paste.kde.org/723140/

I also saw this exeption when rxtx were not instaled but now everything working fine ( if its not root only )


majenko

Fri, 12 Apr 2013 17:10:18 +0000

Hmmm... definitely rxtx related...

There's 2 parts to RXTX - the RXTXcomm.jar in lib, and the "native" RXTX library that it relies on.

My system has /usr/lib/jni/librxtxSerial.so which is a symbolic link to librxtxSerial-2.2pre1.so

It's provided by the librxtx-java package. Is that what you installed to get it working as a normal user?

Also, it could possibly be something in root's preferences file. Try deleting /root/.mpide/preferences.txt and running it again.


yaroslav kishchenko

Fri, 12 Apr 2013 17:43:17 +0000

My system has /usr/lib/jni/librxtxSerial.so which is a symbolic link to librxtxSerial-2.2pre1.so It's provided by the librxtx-java package. Is that what you installed to get it working as a normal user?

yes i have the same and i instal that rxtx package

i tried to lunch mpide without preferences and with regular user preferences( i copyed them to root )

nothing helped

also if you starts as a root do you get this dialog as i got it asks you to choose folder for scretches


majenko

Fri, 12 Apr 2013 18:21:06 +0000

You would normally get the sketchbook selection dialogue if there was no preferences.txt file.

Just delete the preferences.txt file from root and run mpide as root - don't copy the user one in. It will create a new fresh one for you.


yaroslav kishchenko

Fri, 12 Apr 2013 20:03:31 +0000

don't work at all i deletes root preferences well they appeared again after i tried to execute mpide as root ( i guess its normal ) i even delete /root/skracthbook now i dont have that dialog it just bumps to exception


majenko

Sat, 13 Apr 2013 10:14:21 +0000

Most problems are cured by deleting preferences... You've pretty much exhausted my ideas now.

I do recall having a similar issue once, a long time back, and I can't for the life of me remember how I cured it.

It involved deleting something from lib/, and the system re-created it for me at next run. I really can't recall what it was though. Something serial related, I remember that.

Of course, one question I have failed to ask so far:

Why do you want to run it as root? Running any application as root is a Really Bad Ideaâ„¢ and should be avoided.


yaroslav kishchenko

Sat, 13 Apr 2013 13:16:11 +0000

anyway thank you for your help launching regular thing as root is a bad idea i agree sure i can work without that thing but its just question i wanted to solve another problem that i wanted automate a little bit launching MPIDE from my KDE when i make menu item in kickoff widget i cant launch in if I mark that MPIDE should be run with console than i see all output that is i think the same as if I launch it as root I already started thread in KDE forum they say that my program are not running as root also they can put it in menu item but i cant its all the same that you launch it as root but i cant i thought if i solve that problem about launching as root that will solve problem about KDE

Well it seems that i need every time go to console and launch it not a big deal of course :roll:


majenko

Sat, 13 Apr 2013 13:34:24 +0000

Have you tried downloading the latest version and running it as a clean install?


yaroslav kishchenko

Sat, 13 Apr 2013 13:42:10 +0000

i downloaded it a few days ago and i think its the newest here the name of the folder it extracted mpide-0023-linux-20120903 is not it latest what is clean install does this software should be installed i do not see any make file or any thing else isn't it just launches from script?

it would be nice if MPIDE for linux was packeged as deb or rpm at least when it came out of the box it did not seened to me that its just regular linux software i was looking for make file or readme.txt only after i read wiki i understand what dependecies are missed


majenko

Sat, 13 Apr 2013 13:48:52 +0000

Yes, proper installers would (will) be nice. I believe it's on the cards. A proper repository (I'd use launchpad personally) so apt-get works properly would be an absolute joy.

There are much newer "experimental" builds available: [url]http://chipkit.s3.amazonaws.com/index.html?sort=lastmod&sortdir=desc[/url] - try the mpide-0023-linux32-20130324-test.tgz build.

By a "clean" install I mean just extracted into its own folder and run from there.