LinuxQuestions.org
Visit Jeremy's Blog.
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 05-02-2017, 08:00 AM   #1
burdi01
Member
 
Registered: Dec 2010
Location: The Netherlands
Distribution: Slackware, Xubuntu
Posts: 268

Rep: Reputation: 36
Current64: Where does the /.cache file come from?


Current64: After each boot, before starting X I already have an empty /.cache file, for which I cannot find "who" creates it.
Taking the risk to sound stupid, but is there anyone who knows?

Last edited by burdi01; 05-02-2017 at 08:51 AM.
 
Old 05-02-2017, 11:51 AM   #2
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 5,125

Rep: Reputation: 2903Reputation: 2903Reputation: 2903Reputation: 2903Reputation: 2903Reputation: 2903Reputation: 2903Reputation: 2903Reputation: 2903Reputation: 2903Reputation: 2903
It doesn't occur on my frankenstein 14.1 install or my normal 14.2 install. I don't have any -current installs to test. However, my first guess is this is a culprit of 3rd-party software you have installed. Maybe an rc.d script that is missing a variable being set?

First thing I'd try is to run fgrep ".cache" /etc/rc.d/* to see if it can find any files containing .cache in them (fgrep prevents regex from being used, so it interprets the . as a literal period, not as a wildcard like in normal regex... I can never remember how to properly escape it for a regular grep). It might also be worth checking any 3rd-party programs you have starting up automatically. If the file isn't being created directly by a script in /etc/rc.d/, it could be by one of the scripts called by one of those rc.d scripts (like rc.program calls /usr/bin/program, which may also be a shell script).

If you don't want to do all that searching, you could try disabling all your 3rd-party items in /etc/rc.d/ (don't forget stuff in rc.local) and see if the file is still created when you reboot. Don't forget to remove the .cache before you restart!

Last edited by bassmadrigal; 05-02-2017 at 11:52 AM.
 
1 members found this post helpful.
Old 05-02-2017, 12:14 PM   #3
notKlaatu
Senior Member
 
Registered: Sep 2010
Location: Wellington, New Zealand
Distribution: Slackware, Fedora
Posts: 1,039

Rep: Reputation: 690Reputation: 690Reputation: 690Reputation: 690Reputation: 690Reputation: 690
Are you logging in to X as root? KDE Plasma might be creating those dirs for root, and dumping them, incorrectly, in /.

I did two minutes (OK, maybe it was more like 90 seconds) of testing and it appears that this happens on Fedora 25 (I'm at work right now, so that's the machine I have handy).
 
Old 05-03-2017, 05:50 AM   #4
burdi01
Member
 
Registered: Dec 2010
Location: The Netherlands
Distribution: Slackware, Xubuntu
Posts: 268

Original Poster
Rep: Reputation: 36
I did scan the /etc directory for ".cache" (and even for "cache") and followed the boot sequence up to and including logging in - I boot into lvl3, so no X. As I could not find a "culprit" I posted my question.
Today I repeated this procedure, and again to no avail...
I took the way of the least resistance and delete the /.cache directory in my /etc/rc.d/rc.local.
Thank you for responding.
 
Old 05-03-2017, 05:57 AM   #5
pan64
LQ Guru
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 11,016

Rep: Reputation: 3276Reputation: 3276Reputation: 3276Reputation: 3276Reputation: 3276Reputation: 3276Reputation: 3276Reputation: 3276Reputation: 3276Reputation: 3276Reputation: 3276
looks like it was created during installation (at least on ubuntu) and also there is a file inside:
Code:
/.cache/dconf/user
containing 00 (2 times 0).
 
Old 05-03-2017, 06:03 AM   #6
burdi01
Member
 
Registered: Dec 2010
Location: The Netherlands
Distribution: Slackware, Xubuntu
Posts: 268

Original Poster
Rep: Reputation: 36
@pan64: I delete that directory, but every time after a reboot it is back ...
As an aside, it is not present on my Xubuntu installation.

Last edited by burdi01; 05-03-2017 at 06:04 AM.
 
Old 05-03-2017, 06:08 AM   #7
pan64
LQ Guru
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 11,016

Rep: Reputation: 3276Reputation: 3276Reputation: 3276Reputation: 3276Reputation: 3276Reputation: 3276Reputation: 3276Reputation: 3276Reputation: 3276Reputation: 3276Reputation: 3276
looks like it is created by apparmor
 
Old 05-03-2017, 06:12 AM   #8
55020
Senior Member
 
Registered: Sep 2009
Location: Yorks. W.R. 167397
Distribution: Slackware
Posts: 1,234
Blog Entries: 4

Rep: Reputation: Disabled
*Lots* of software creates and uses subdirectories of ~/.cache -- it tends to be packages that also use .local and .config. If you're cool with .local and .config (and you probably are, unless you don't want software to remember your config from one login to the next) then you should also be cool with .cache. Life's too short to stop software trying to speed itself with a bit of cacheing.

It's another fdo idea by the way (https://standards.freedesktop.org/ba...ec-latest.html), and yes, that's our friend Mr Lovebucket on the authors list.

From the spec, you can try to specify an alternative name with XDG_CACHE_HOME if it really bothers you.

Edit: here's a totally random list of totally random stuff that uses it:
calibre darktable dconf fontconfig fontforge g-ir-scanner geeqie gegl-0.2 google-chrome gpg-agent-info gstreamer-1.0 guile gvfs-burn inkscape instantfpc keybase keyring-* matplotlib mc moonchild productions mozilla osmgpsmap pip sessions spotify thumbnails thunderbird vlc webkit xfce4

Last edited by 55020; 05-03-2017 at 06:16 AM.
 
Old 05-03-2017, 07:34 AM   #9
montagdude
Member
 
Registered: Apr 2016
Distribution: Slackware
Posts: 995

Rep: Reputation: 716Reputation: 716Reputation: 716Reputation: 716Reputation: 716Reputation: 716Reputation: 716
Quote:
Originally Posted by 55020 View Post
*Lots* of software creates and uses subdirectories of ~/.cache -- it tends to be packages that also use .local and .config. If you're cool with .local and .config (and you probably are, unless you don't want software to remember your config from one login to the next) then you should also be cool with .cache. Life's too short to stop software trying to speed itself with a bit of cacheing.
You've convinced me. I'm okay with ~/.cache.

Quote:
Originally Posted by 55020 View Post
It's another fdo idea by the way (https://standards.freedesktop.org/ba...ec-latest.html), and yes, that's our friend Mr Lovebucket on the authors list.
Wait, I take it back. Now I hate it!
 
Old 05-03-2017, 07:35 AM   #10
burdi01
Member
 
Registered: Dec 2010
Location: The Netherlands
Distribution: Slackware, Xubuntu
Posts: 268

Original Poster
Rep: Reputation: 36
Note to everyone: I am talking about an empty /.cache directory, not one like ~/.cache !
 
Old 05-03-2017, 07:54 AM   #11
55020
Senior Member
 
Registered: Sep 2009
Location: Yorks. W.R. 167397
Distribution: Slackware
Posts: 1,234
Blog Entries: 4

Rep: Reputation: Disabled
ooooooo!!! sorry burdi01, I've made myself look stupid again

As you say it definitely shouldn't be there (of all places). Thanks for the report! If you can identify its creation time to the nearest second, hopefully that'll narrow down what did it. And then we can smite the damn thing.
 
Old 05-03-2017, 08:51 AM   #12
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 5,125

Rep: Reputation: 2903Reputation: 2903Reputation: 2903Reputation: 2903Reputation: 2903Reputation: 2903Reputation: 2903Reputation: 2903Reputation: 2903Reputation: 2903Reputation: 2903
Have you tried stopping any of your custom rc.d entries? That would mean making rc.d and any non-official rc.d script non-executable. If it still occurs, then it would likely be something in -current itself and not any of your 3rd-party software. But I can't think of any official Slackware packages that would create that directory during the boot process, so I'm expecting it is a 3rd-party software that doesn't have its variables set up properly.

The following command will list all executable files in /etc/rc.d/, if you also include your contents of rc.local, it might help us narrow down your possible culprits.

Code:
find /etc/rc.d/ -maxdepth 1 -perm -111 -type f
 
Old 05-03-2017, 01:34 PM   #13
rworkman
Slackware Contributor
 
Registered: Oct 2004
Location: Tuscaloosa, Alabama (USA)
Distribution: Slackware
Posts: 2,303

Rep: Reputation: 808Reputation: 808Reputation: 808Reputation: 808Reputation: 808Reputation: 808Reputation: 808
I'd lean toward finding out what's running as root (or at least starting as root and maybe dropping privs), then see if any of them have a $HOME directory that is either / or unset (which might cause them to default to /).
 
1 members found this post helpful.
Old 05-03-2017, 02:27 PM   #14
gmgf
Senior Member
 
Registered: Jun 2012
Location: Bergerac, France
Distribution: Slackware
Posts: 1,543

Rep: Reputation: 602Reputation: 602Reputation: 602Reputation: 602Reputation: 602Reputation: 602
this .cache is recreated after reboot or at boot.

Last edited by gmgf; 05-03-2017 at 02:51 PM.
 
Old 05-03-2017, 02:45 PM   #15
Darth Vader
Senior Member
 
Registered: May 2008
Location: Romania
Distribution: DARKSTAR Linux 2008.1
Posts: 2,444

Rep: Reputation: 982Reputation: 982Reputation: 982Reputation: 982Reputation: 982Reputation: 982Reputation: 982Reputation: 982
That nasty folder on / appeared after the latest font adventures...
 
  


Reply


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] latest hplip on current64 Launfal Slackware 34 06-10-2016 06:27 PM
[SOLVED] Current64 sound has a mind of its own Gordie Slackware 20 02-22-2016 06:32 AM
[SOLVED] Pdfshuffler and poppler in current64 aszabo Slackware 3 02-01-2016 11:01 AM
[SOLVED] -current64 aclocal segfault KaMii Slackware 8 11-07-2015 12:46 AM
Autokey and current64 charlie_lab Slackware 4 03-20-2010 03:56 PM

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

All times are GMT -5. The time now is 01:40 PM.

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