View unanswered posts    View active topics

All times are UTC - 6 hours





Post new topic Reply to topic  [ 37 posts ] 
Go to page 1, 2, 3  Next

Print view Previous topic   Next topic  
Author Message
Search for:
PostPosted: Thu Jul 28, 2005 1:51 pm 
Offline
Joined: Fri Jun 24, 2005 3:22 pm
Posts: 124
Hi, and thanks in advance to your help. I've only noticed one bug in this latest build that prevents it from being great for use by non-technical end users: the GUI becomes unresponsive at times.

When I'm using the system myself, I'm often logged in via ssh from my PowerBook, and so I quickly solve the problem with one command as root:

/etc/init.d/gdm restart

After one second of blah, blah, everything's back to normal.

If I were a shell script hipster, I'd write a script that maps /etc/init.d/gdm restart, oh, for instance to Ctrl-Alt-R or Ctrl-Alt-. -- something like that.

Armed with this, my intelligent yet uneducated roommates could easily solve any problems themselves.

Of course, feel free to make a suggestion if you think you know of something better to use than /etc/init.d/gdm restart .

Are there any shell script hipsters that can show me how?

Thank you very much. :)

Peter

_________________
AMD Athlon XP 2800+
MSI K7N2 Delta2 ATX w/FX5200 AGP video
2X256MB PC3200 RAM
Maxtor 250GB drive (master on IDE 1)
Pioneer DVR-109 (master on IDE 2)
Antec Overture II ATX case with 330watts
Hauppauge 250 in PCI slot 2


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jul 28, 2005 3:35 pm 
Offline
Joined: Mon Oct 06, 2003 10:38 am
Posts: 4978
Location: Nashville, TN
well lets see a completely bland with no error checking or anything fancy would look something like

Code:
#!/bin/bash
/etc/init.d/gdm restart


if would of course then have to be made executable and now that I think of it you would have to be root to run it unless you enabled sudo then you would have to add sudo to the script. also there are some posts about having the remote do this for you, though it would depend on just how unresponsive the system has become as to wether or not it would work. you may want to search for those.

_________________
Have a question search the forum and have a look at the KnoppMythWiki.

Xsecrets


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jul 28, 2005 3:53 pm 
Offline
Joined: Fri Jun 24, 2005 3:22 pm
Posts: 124
Thanks. Yes, the script would have to run as root to work. I found this article:

http://wilsonet.com/mythtv/tips.php

(Scroll down to "Make Myth even more wife-friendly".) That's where I got the original idea, but why use the remote when many posts point out that the installations of various things breaks this functionality?

Also, we don't have much call to use the remote. We have Dish Network, which as you probably know doesn't have the proper serial interface to make channel changing possible.

Hmmm, unless you mean that I can hack into the Dish Network remote. That would be cool. But I don't think that's what you meant. :D

Is there a way to make this executable by root even when the normal user executes it with a single keyboard command?

Would you think it better to restart the myth frontend or gdm for this application?

Thanks.

_________________
AMD Athlon XP 2800+
MSI K7N2 Delta2 ATX w/FX5200 AGP video
2X256MB PC3200 RAM
Maxtor 250GB drive (master on IDE 1)
Pioneer DVR-109 (master on IDE 2)
Antec Overture II ATX case with 330watts
Hauppauge 250 in PCI slot 2


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jul 28, 2005 6:45 pm 
Offline
Joined: Mon Oct 06, 2003 10:38 am
Posts: 4978
Location: Nashville, TN
If you don't have anything setup to change the channels on the dish box how do you record what you want to? And if you don't have or use a remote with mythtv how do you pause rewind or fast forward?

_________________
Have a question search the forum and have a look at the KnoppMythWiki.

Xsecrets


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jul 28, 2005 6:51 pm 
Offline
Joined: Fri Jun 24, 2005 3:22 pm
Posts: 124
Like everyone with Dish Network, we leave in on the channel we want to record and use a post-it note for people.

It certainly llimits the functionality, but doesn't erase it. And it could be an incentive for us to switch.

Anyhow, can we map this to our wireless keyboard? That would be more useful than mapping it to the remote.

_________________
AMD Athlon XP 2800+
MSI K7N2 Delta2 ATX w/FX5200 AGP video
2X256MB PC3200 RAM
Maxtor 250GB drive (master on IDE 1)
Pioneer DVR-109 (master on IDE 2)
Antec Overture II ATX case with 330watts
Hauppauge 250 in PCI slot 2


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jul 28, 2005 6:56 pm 
Offline
Joined: Mon Oct 06, 2003 10:38 am
Posts: 4978
Location: Nashville, TN
most people I've talked to with satelite use an irblaster so that myth can change the channel on the statelite box itself when it's ready to record.

I don't know of any way to map it to a key on the keyboard, but I haven't messed with that kind of stuff very much, so It might be possible.

_________________
Have a question search the forum and have a look at the KnoppMythWiki.

Xsecrets


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jul 28, 2005 7:01 pm 
Offline
Joined: Fri Jun 24, 2005 3:22 pm
Posts: 124
Well, its good to know that people have had success with Dish Network. I'll start reading up on ir blaster.

However, that will take time and experimentation. Hopefully, I'll find some keyboard solution in the meantime.

Thanks.

_________________
AMD Athlon XP 2800+
MSI K7N2 Delta2 ATX w/FX5200 AGP video
2X256MB PC3200 RAM
Maxtor 250GB drive (master on IDE 1)
Pioneer DVR-109 (master on IDE 2)
Antec Overture II ATX case with 330watts
Hauppauge 250 in PCI slot 2


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jul 29, 2005 5:50 pm 
Offline
Joined: Fri Jun 24, 2005 3:22 pm
Posts: 124
Hi. I've found something that works for now, but that restart gdm command would be quicker. Darn.

Here's the deal:

Crtl-Alt-Backspace works except the uneducated end user have to wait 30 seconds for it to begin to re-login.

If you exit Myth and Right-Click on the Desktop, you can select

Apps --> System --> GDM Setup then authenticate and lood at the General tab. Lower the timer for the auto login to 5 seconds and then click close.

Now it relogs in after 5 seconds. Bummer: You can set it for less than 5 seconds but it don't work! It will override you and countdown from 5 anyway.

Again, this will help make this more "roommate friendly", but I'm hoping someone can post a solution that maps a keyboard command to root activation of

/etc/init.d/gdm restart

since it is much faster and doesn't restart stuff that doesn't need restarting.

I've found some keyboard mapping software, but most is for KDE, not Gnome. For the stuff that looks like it might work, I'm still studying and googling cuz I just don't understand everything they're talking about.

Check out:

http://rick.vanrein.org/linux/funkey/

and

http://www.geocities.com/wmalms/#XHKEYS

Thanks for reading my post.

_________________
AMD Athlon XP 2800+
MSI K7N2 Delta2 ATX w/FX5200 AGP video
2X256MB PC3200 RAM
Maxtor 250GB drive (master on IDE 1)
Pioneer DVR-109 (master on IDE 2)
Antec Overture II ATX case with 330watts
Hauppauge 250 in PCI slot 2


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jul 29, 2005 6:17 pm 
Offline
Joined: Mon Oct 06, 2003 10:38 am
Posts: 4978
Location: Nashville, TN
well before you waste too much time knoppmyth does not use gnome. it just uses the gdm from it. for a window manager it uses fluxbox.

_________________
Have a question search the forum and have a look at the KnoppMythWiki.

Xsecrets


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jul 29, 2005 6:26 pm 
Offline
Joined: Fri Jun 24, 2005 3:22 pm
Posts: 124
Thank you. I was unaware of the subtle differences between GDM and Gnome. I'd thought it just stood for Gnome Display Manager and was the same thing.

No wonder I wasn't finding the conf file everyone was talking about!

Now googling flux info...

_________________
AMD Athlon XP 2800+
MSI K7N2 Delta2 ATX w/FX5200 AGP video
2X256MB PC3200 RAM
Maxtor 250GB drive (master on IDE 1)
Pioneer DVR-109 (master on IDE 2)
Antec Overture II ATX case with 330watts
Hauppauge 250 in PCI slot 2


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jul 29, 2005 11:01 pm 
Offline
Joined: Fri Jun 24, 2005 3:22 pm
Posts: 124
From my research, this works; in reality, it does not. How can I bend space and time to make this work? Thanks.

create the shell script:
nano /usr/local/bin/gdm_restart.sh

add text:
#!/bin/bash
/etc/init.d/gdm restart.sh

Ctrl-x
y

Set it to continue to be owned by root, but executable my a common slob and act with root permissions when it does:
chmod a+s /usr/local/bin/gdm_restart.sh

Edit the fluxbox keyboard commands to make Ctrl-Alt-r execute it:
nano /etc/X11/fluxbox/keys

add this at the bottom of the file:
Mod1 r :ExecCommand ./usr/local/bin/restart_gdm.sh

Ctrl-x
y

I'm hoping that I'm doing one small thing wrong that fresh eyes may spot. :D

Bibliography:
http://fluxbox.sourceforge.net/docbook.php

http://linuxreviews.org/beginner/Bash-B ... index.html

_________________
AMD Athlon XP 2800+
MSI K7N2 Delta2 ATX w/FX5200 AGP video
2X256MB PC3200 RAM
Maxtor 250GB drive (master on IDE 1)
Pioneer DVR-109 (master on IDE 2)
Antec Overture II ATX case with 330watts
Hauppauge 250 in PCI slot 2


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jul 29, 2005 11:03 pm 
Offline
Joined: Mon Oct 06, 2003 10:38 am
Posts: 4978
Location: Nashville, TN
while you were modding it to run su root did you also mod it to be executable?

_________________
Have a question search the forum and have a look at the KnoppMythWiki.

Xsecrets


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jul 29, 2005 11:20 pm 
Offline
Joined: Fri Jun 24, 2005 3:22 pm
Posts: 124
Thank you very much.

I just ran:

chmod +x /usr/local/bin/restart_gdm.sh

and the output from:

ls -l /usr/local/bin/restart_gdm.sh

is

-rwsr-sr-x 1 root root 37 Jul 29 20:56 /usr/local/bin/restart_gdm.sh

And it doesn't work. Drag. Another dumb mistake?

_________________
AMD Athlon XP 2800+
MSI K7N2 Delta2 ATX w/FX5200 AGP video
2X256MB PC3200 RAM
Maxtor 250GB drive (master on IDE 1)
Pioneer DVR-109 (master on IDE 2)
Antec Overture II ATX case with 330watts
Hauppauge 250 in PCI slot 2


Top
 Profile  
 
 Post subject:
PostPosted: Sat Jul 30, 2005 10:21 am 
Offline
Joined: Thu Mar 25, 2004 11:00 am
Posts: 9551
Location: Arlington, MA
The setuid and setgid bits aren't honored on shell scripts... This is mostly because the #! magic actually ends up running /bin/bash with the script file as an argument and bash is not setuid/setgid. There are various other reasons associated with security however.


Top
 Profile  
 
 Post subject:
PostPosted: Sat Jul 30, 2005 10:33 am 
Offline
Joined: Fri Jun 24, 2005 3:22 pm
Posts: 124
Thanks for getting back to me. Guess I'm groping in the dark.

As you know, I would love to have some keyboard command run as root:

/etc/init.d/gdm restart

because that very quickly unsticks the GUI when stuck. I'm happy to read documentation and try to figure it out (as I have been), but if I'm approaching this from the wrong direction, please let me know.

Is there a command on one line that I can enter into fluxbox?

Or is there a way to make that command doable by the mythtv user in addition to the super user? I've been reading multiple Linux newbie guides and googling things like '"shell script" "as root"', etc.

_________________
AMD Athlon XP 2800+
MSI K7N2 Delta2 ATX w/FX5200 AGP video
2X256MB PC3200 RAM
Maxtor 250GB drive (master on IDE 1)
Pioneer DVR-109 (master on IDE 2)
Antec Overture II ATX case with 330watts
Hauppauge 250 in PCI slot 2


Top
 Profile  
 

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 37 posts ] 
Go to page 1, 2, 3  Next



All times are UTC - 6 hours




Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB® Forum Software © phpBB Group

Theme Created By ceyhansuyu