LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 09-04-2017, 05:16 AM   #1
igadoter
Member
 
Registered: Sep 2006
Location: wroclaw, poland
Distribution: slackware 12.2, scientific linux 6.4, knoppix 7.2, salix 14.1
Posts: 971

Rep: Reputation: Disabled
No TMP dfined in /etc/profile ? setconsolefont does not work


Hi,
sorry for inconvenience if this is not very readable, I'm posting using Lynx, the first time, don't know, the result.

I just tried to change my console font, with help of script /usr/bin/setconsolefont, but it doesn't work for common user,
I was curious why - I found that script expects the system variable TMP to be set. I was surprised when I found that
TMP is not set system-wide in /etc/profile. Is there any particular reason why TMP needs to be set per user?
 
Old 09-04-2017, 06:20 AM   #2
55020
Senior Member
 
Registered: Sep 2009
Location: Yorks. W.R. 167397
Distribution: Slackware
Posts: 1,128
Blog Entries: 4

Rep: Reputation: 1548Reputation: 1548Reputation: 1548Reputation: 1548Reputation: 1548Reputation: 1548Reputation: 1548Reputation: 1548Reputation: 1548Reputation: 1548Reputation: 1548
The first few lines of /usr/bin/setconsolefont say this:

Code:
if [ "$TMP" = "" ]; then
  TMP=/var/log/setup/tmp
fi
so no, it doesn't expect TMP to be set; if TMP isn't set, setconsolefont will use /var/log/setup/tmp
 
1 members found this post helpful.
Old 09-04-2017, 07:40 AM   #3
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-14.2 on Lenovo Thinkpad W520
Posts: 7,763

Rep: Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691
The purpose of setconsolefont is to set a default font system wide writing a file /etc/rc.d/rc.font.

This should not be allowed to a common user, only to root.

If you want to set a font for a common user, use setfont instead.

If you really want to make your setting system wide run as root.

Last edited by Didier Spaier; 09-04-2017 at 07:42 AM.
 
1 members found this post helpful.
Old 09-04-2017, 08:57 AM   #4
igadoter
Member
 
Registered: Sep 2006
Location: wroclaw, poland
Distribution: slackware 12.2, scientific linux 6.4, knoppix 7.2, salix 14.1
Posts: 971

Original Poster
Rep: Reputation: Disabled
There is problem: common user has no permission to write in /var/log/setup/tmp
If setcosolefont is only for root user then it is unclear why actually at all TMP
is being used in the script. It can be set dy default to use /var/log/setup/tmp.
I rather suspect that issue is artefact from the past versions of setconsolefont.

Last edited by igadoter; 09-04-2017 at 09:05 AM. Reason: addons
 
Old 09-04-2017, 09:27 AM   #5
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-14.2 on Lenovo Thinkpad W520
Posts: 7,763

Rep: Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691
Quote:
Originally Posted by igadoter View Post
There is problem: common user has no permission to write in /var/log/setup/tmp
There is no problem. This directory is to be used only by root.
Quote:
If setcosolefont is only for root user then it is unclear why actually at all TMP
is being used in the script. It can be set dy default to use /var/log/setup/tmp.
I rather suspect that issue is artefact from the past versions of setconsolefont.
There is no issue at all with setconsolefont. Just run it as root as intended.

The script is written in such a way that it works in an installed system as during installation. You can check looking at it.
 
1 members found this post helpful.
Old 09-11-2017, 06:35 AM   #6
igadoter
Member
 
Registered: Sep 2006
Location: wroclaw, poland
Distribution: slackware 12.2, scientific linux 6.4, knoppix 7.2, salix 14.1
Posts: 971

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Didier Spaier View Post
There is no problem. This directory is to be used only by root.
There is no issue at all with setconsolefont. Just run it as root as intended.
Well, as it is now there is not much use for this script. Except when installing system.
 
  


Reply

Tags
setconsolefont, tmp


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Terminus fonts absent from setconsolefont in -current jprzybylski Slackware 3 08-08-2013 12:55 PM
Samba creates huge tmp, prf files on XP client and doesnt load profile. avinash.rao Ubuntu 3 07-07-2011 05:23 AM
[NB Question]setconsolefont - where are the fonts? stevesk Slackware 2 07-16-2006 05:33 PM
got ALSA to work in root, need help getting it to work in my user profile ic3 Slackware 2 11-28-2003 11:32 PM
tmp in profile u4113072 Linux - Software 0 12-23-2002 09:34 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 07:21 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration