View unanswered posts    View active topics

All times are UTC - 6 hours





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

Print view Previous topic   Next topic  
Author Message
Search for:
PostPosted: Sun Dec 26, 2004 11:07 am 
Offline
Joined: Sun Nov 14, 2004 2:39 pm
Posts: 113
I've searched the forums and have not been able to find this issue.
For some reason I have to do a chmod 777 mythbackend.log to get the backend to start. Otherwise it give me a permission error. After doing the chmod 777 it will work until some arbitrary time in the future (usually until I reboot). Not sure what is going on here. Logs do not point to anything unusual.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Dec 27, 2004 3:28 am 
i have extactly the same problem.

i find i have to do it every couple of weeks or so. i think its when i logrotate is done


Top
  
 
PostPosted: Wed Jan 12, 2005 7:04 am 
Offline
Joined: Sun Nov 14, 2004 2:39 pm
Posts: 113
I think you are right. My mythbakend.log is allways a new empty file.
I also find I can get backend to start if I remove the empty mythbackend.log and restart backend. What script makes the new log file when they rotate?


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jan 12, 2005 9:26 pm 
Offline
Joined: Thu Mar 25, 2004 11:00 am
Posts: 9551
Location: Arlington, MA
Why do inexperienced Unix users always seem to gravitate to the horrible chmod 777 superstition? I've got an ongoing problem with the DBAs and a few other people at work doing this. Even people who should know better... :(

1) You should always use the symbolic arguments for chmod rather than the octal numbers. Then you can actually remember the right thing to do rather than blindly doing the 777 lemming thing.

2) You do NOT need 777 (Read, Write, and eXecute for User, Group, and Other - aka chmod ugo+rwx). You *might* need 666 (aka chmod ugo=rw) but that ignores the REAL source of your problem.

3) The real source of your problem is that your /var/log/mythtv directory and the files in it have the wrong ownership and/or permissions. To fix it please logon as root and do the following steps:
Code:
chown mythtv:mythtv /var/log/mythtv /var/log/mythtv/*
chmod u=rwx,g=rwxs,o=rx /var/log/mythtv
chmod u=rw,go=r /var/log/mythtv/*

This will solve your problem once and for all and keep you from perpetrating the horror that is chmod 777.

BTW - Cesman there seems to be something really screwy wrong with directory and file permssions in a lot of R4V5 installs. I don't know if this is an artifact of a corrupted ISO image, or something they're doing during the install, or ... but there is definitely a pattern.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jan 14, 2005 8:44 pm 
Offline
Joined: Fri Sep 19, 2003 7:05 pm
Posts: 5088
Location: Fontana, Ca
Yes, I know... That is probably because I did it on the road and not at my dev box. MythTV 0.16 was about to be released and I was on a business trip. At thing point, I'd rather work on R5 than R4V6. That is not to state that they won't be an R4V6 before R5....

_________________
cesman

When the source is open, the possibilities are endless!


Top
 Profile  
 
PostPosted: Fri Mar 04, 2005 4:59 pm 
Offline
Joined: Sun Nov 14, 2004 2:39 pm
Posts: 113
Have followed all the helpful suggestions on this thread to set permissions. Still have issue with backend not starting sometimes on reboot because of permissions.

When it fails and /var/log/mythtv is checked :

-rw-r--r-- 1 mythtv adm 0 Mar 4 16:44 mythbackend.log
-rw-r----- 1 root adm 74488 Mar 4 15:14 mythbackend.log.0
-rw-r----- 1 root adm 1746 Feb 20 21:51 mythbackend.log.1.gz
-rw-r--r-- 1 mythtv mythtv 2564 Feb 27 06:25 mythbackend.log.2.gz
-rw-r--r-- 1 mythtv mythtv 1255 Feb 26 06:25 mythbackend.log.3.gz
-rw-r--r-- 1 mythtv mythtv 633 Feb 24 06:25 mythbackend.log.4.gz
-rw-r--r-- 1 mythtv mythtv 610 Feb 23 06:25 mythbackend.log.5.gz
-rw-r--r-- 1 mythtv mythtv 1095 Feb 22 06:25 mythbackend.log.6.gz
-rw-r--r-- 1 mythtv mythtv 524 Feb 21 06:25 mythbackend.log.7.gz

Seems like something is creating the mythbackend.log with permissions for "adm" . when I delete the 0 size mythbackend.log then restart the backend successfully:

-rw-r--r-- 1 mythtv mythtv 492 Mar 4 16:44 mythbackend.log
-rw-r----- 1 root adm 74488 Mar 4 15:14 mythbackend.log.0
-rw-r----- 1 root adm 1746 Feb 20 21:51 mythbackend.log.1.gz
-rw-r--r-- 1 mythtv mythtv 2564 Feb 27 06:25 mythbackend.log.2.gz
-rw-r--r-- 1 mythtv mythtv 1255 Feb 26 06:25 mythbackend.log.3.gz
-rw-r--r-- 1 mythtv mythtv 633 Feb 24 06:25 mythbackend.log.4.gz
-rw-r--r-- 1 mythtv mythtv 610 Feb 23 06:25 mythbackend.log.5.gz
-rw-r--r-- 1 mythtv mythtv 1095 Feb 22 06:25 mythbackend.log.6.gz
-rw-r--r-- 1 mythtv mythtv 524 Feb 21 06:25 mythbackend.log.7.gz


This is what is shown.

Seems like some process somewhere is initializing the log file for "adm" but the backend is running under "mythtv".

Kind of a minor annoyance.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Mar 04, 2005 6:14 pm 
Offline
Joined: Mon Oct 06, 2003 10:38 am
Posts: 4978
Location: Nashville, TN
I'm curious as to why only a few people experience this. I've run almost every alpha and never had the problem.

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

Xsecrets


Top
 Profile  
 
 Post subject:
PostPosted: Fri Mar 04, 2005 7:29 pm 
Offline
Joined: Thu Mar 25, 2004 11:00 am
Posts: 9551
Location: Arlington, MA
I think that somewhere along the way the UIDs or GIDs Cecil used for the image got changed somehow and when upgrading from older versions you end up with a mismatched set. At a guess this happened between R4V4 and R4V5. I definitely noticed some issues with this going from R4V4 + 0.16 debs to R5A12...


Top
 Profile  
 
 Post subject:
PostPosted: Fri Mar 04, 2005 10:08 pm 
Offline
Joined: Wed Feb 18, 2004 9:07 pm
Posts: 89
I upgraded from R4V2 to 0.16 debs to R5A10, and I had a TON of uid/gid problems. A bunch of directories had "cron" as owner, and a bunch more had some numeric userid as owner (everything in /myth/tv, e.g.)

It wasn't a big deal to correct, once I figured out what was going on.

_________________
R5Fxx

Home-Brewed Mythic Dragon Clone
200GB WD IDE /myth
2x250GB WD IDE (lvm) /myth/tv


Top
 Profile  
 
 Post subject:
PostPosted: Fri Mar 04, 2005 11:34 pm 
Offline
Joined: Thu Mar 25, 2004 11:00 am
Posts: 9551
Location: Arlington, MA
Yeah, most likely the problem arises from restoring the /etc/passwd and /etc/group from the backup. I have an idea on how to verify that, but I'm fighting other battles at the moment.


Top
 Profile  
 
 Post subject:
PostPosted: Sat Mar 05, 2005 12:06 am 
Offline
Joined: Fri Sep 19, 2003 7:05 pm
Posts: 5088
Location: Fontana, Ca
The only thing under /etc that is restored is /etc/mythtv

_________________
cesman

When the source is open, the possibilities are endless!


Top
 Profile  
 
 Post subject:
PostPosted: Sat Mar 05, 2005 12:54 am 
Offline
Joined: Thu Mar 25, 2004 11:00 am
Posts: 9551
Location: Arlington, MA
Well, that kind of shoots that theory all to pieces doesn't it... ;-)


Top
 Profile  
 
 Post subject:
PostPosted: Sat Mar 05, 2005 1:21 am 
Offline
Joined: Fri Sep 19, 2003 7:05 pm
Posts: 5088
Location: Fontana, Ca
The reason the different uid/gid from R4 to R5 is because R5 is constructed from scratch. The users and groups were added in a different order than R4 (Knoppix).

_________________
cesman

When the source is open, the possibilities are endless!


Top
 Profile  
 
 Post subject: Hate to burst bubble
PostPosted: Sat Mar 05, 2005 5:26 am 
Offline
Joined: Sun Nov 14, 2004 2:39 pm
Posts: 113
I'm new to the whole MythTV KnoppMyth scene. My install is a pristine KnoppMyth Install V4R5. I did not come from a privious install........

Seems to be related to whatever is going on to initialize a new mythbackend.log file. Whenever that is required (Boot time, aging of log files).


Top
 Profile  
 
 Post subject:
PostPosted: Sat Mar 05, 2005 10:33 am 
Offline
Joined: Thu Mar 25, 2004 11:00 am
Posts: 9551
Location: Arlington, MA
Well then the older posts above should answer the question.

- make sure that mythtv has write permissons on the directory, either by ownership or group.

- make sure that mythtv owns the file and has write permissions

Mine looks like this:

Code:
root@black:/myth/mythburn# ls -al /var/log/mythtv/
total 84
drwxrwsr-x   2 mythtv mythtv  4096 Mar  5 06:25 .
drwxr-xr-x  13 root   root    4096 Mar  5 06:26 ..
-rw-r--r--   1 mythtv mythtv   293 Mar  5 06:25 mythbackend.log
-rw-r--r--   1 mythtv mythtv  5334 Mar  5 06:25 mythbackend.log.1
-rw-r--r--   1 mythtv mythtv  7558 Mar  4 06:25 mythbackend.log.2
-rw-r--r--   1 mythtv mythtv  3251 Mar  3 06:25 mythbackend.log.3
-rw-r--r--   1 mythtv mythtv 16187 Mar  2 06:25 mythbackend.log.4
-rw-r--r--   1 mythtv mythtv 34357 Mar  1 06:25 mythbackend.log.5


To enforce this, as root run the following commands:

Code:
mkdir -p /var/log/mythtv/
chown mythtv:mythtv /var/log/mythtv/ /var/log/mythtv/*
chmod ug+rwx,g+s,o=rx /var/log/mythtv/
chmod u=rw,go=r /var/log/mythtv/*


If you're a Unix newbie and are curious about what those do, try using the man (manual page) command to get the scoop. e.g. - man mkdir


Top
 Profile  
 

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



All times are UTC - 6 hours




Who is online

Users browsing this forum: No registered users and 17 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:  
cron
Powered by phpBB® Forum Software © phpBB Group

Theme Created By ceyhansuyu