LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware > Linux - Embedded & Single-board computer
User Name
Password
Linux - Embedded & Single-board computer This forum is for the discussion of Linux on both embedded devices and single-board computers (such as the Raspberry Pi, BeagleBoard and PandaBoard). Discussions involving Arduino, plug computers and other micro-controller like devices are also welcome.

Notices


Reply
  Search this Thread
Old 06-16-2020, 06:35 PM   #16
Completely Clueless
Member
 
Registered: Mar 2008
Location: Marbella, Spain
Distribution: Many and various...
Posts: 899

Original Poster
Rep: Reputation: 70

Quote:
Originally Posted by michaelk View Post
You need to delete to get below 95% and would say at least 100Mb.

sdb2..
Alternatively, how about I obtain an 8Gb SD card (they cost next-to-nothing nowadays) and just 'dd' the original over to that? Otherwise I might risk deleting something that's critical to the functionality (the only user data on it is a few lines of shell script).
 
Old 06-16-2020, 07:08 PM   #17
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,734

Rep: Reputation: 5920Reputation: 5920Reputation: 5920Reputation: 5920Reputation: 5920Reputation: 5920Reputation: 5920Reputation: 5920Reputation: 5920Reputation: 5920Reputation: 5920
Sure.
 
Old 06-17-2020, 12:30 AM   #18
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 19,872
Blog Entries: 12

Rep: Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053
Quote:
Originally Posted by Completely Clueless View Post
Code:
bro@bro-laptop ~/Desktop $ df -hT
Filesystem     Type      Size  Used Avail Use% Mounted on
(...)/dev/sdb2      ext4      1.7G  1.6G     0 100% /media/bro/b7b5ddff-ddb4-48dd-84d2-dd47bf00564a
/dev/sdb1      vfat       56M   19M   38M  34% /media/bro/3312-932F
If that card is really 4GB, then something must have gone wrong formatting it (it is totally possible to create partitions that don't fill the whole card).
I suggest you fire up a graphical tool like gparted and see if the card shows some "unused space".
 
Old 06-17-2020, 01:30 AM   #19
Roken
Member
 
Registered: Oct 2011
Location: Warrington, UK
Distribution: Arch local, Debian on VPS, several RPIs.
Posts: 300
Blog Entries: 1

Rep: Reputation: 55
I'd be tempted to try to use the Pi to expand the filesystem to fill it.

Code:
sudo raspi-config
Choose "Advanced options", and then "Expand the filesystem".
 
Old 06-18-2020, 05:20 PM   #20
Completely Clueless
Member
 
Registered: Mar 2008
Location: Marbella, Spain
Distribution: Many and various...
Posts: 899

Original Poster
Rep: Reputation: 70
I can't even recall now which distro I created it from; probably Raspian I guess, but it was probably the wrong choice. I should have used something leaner and meaner like Puppy perhaps, then this space issue wouldn't have arisen in the first place. I could have got everything on a 1Gb SD card with room to spare.
The *only* things I have added to the core OS are one bash script file, some GPIO program and its associated libraries. A truly tiny amount of stuff compared to the OS, which hogs the lion's share of the Pi's resources.
Does anyone know if a Pi will run okay on a slimmer disto?
 
Old 06-18-2020, 06:17 PM   #21
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,734

Rep: Reputation: 5920Reputation: 5920Reputation: 5920Reputation: 5920Reputation: 5920Reputation: 5920Reputation: 5920Reputation: 5920Reputation: 5920Reputation: 5920Reputation: 5920
Without knowing how the drive is partitioned of if the rest of the drive is unused space we can't say if it can be expanded using raspi-config. Raspian does create a swap partition.

Hindsight is 20/20 but Raspberrypi.org site recommends min 8GB.

The information is a few years old but there are a bunch of distributions. I only use raspbian...
https://elinux.org/RPi_Distributions

Have you looked at /var/log to see if there are old logs that could be deleted? You should be able to go through the obvious directories to see where there might be excess "stuff" or run du to find where?
du -a /sdcard/mount_point/ | sort -n -r | head -n 20

If you are using raspbian without a desktop (i.e the lite version), with GPIO libraries and your bash script file you should be able to rebuild the system on a 8 GB card in a matter of 30 minutes to an hour assuming you have a suitable display or you can add a configuration text file to automatically configure and setup system in headless mode. Since the system is a few years old I assume it isn't a Pi 4 which does things a bit different.

There are a bunch of how-tos.
https://howtoraspberrypi.com/how-to-...eadless-setup/
https://www.tomshardware.com/reviews...w-to,6028.html
 
1 members found this post helpful.
Old 06-22-2020, 06:14 AM   #22
GPGAgent
Senior Member
 
Registered: Oct 2018
Location: Surrey UK
Distribution: Mint 20 xfce 64bit
Posts: 1,026
Blog Entries: 3

Rep: Reputation: 133Reputation: 133
Nobody has mentioned hidden files/folders, check for those.
Code:
ls -a
https://www.rapidtables.com/code/linux/ls/ls-a.html

Or through whatever filemangler you use, usually a View option.

Also empty the Wastebasket folder

Hidden files/folders begin with a .
Code:
jonk@jonk-Len-usff:~$ ls -al
total 232
drwxr-xr-x 41 jonk jonk  4096 Jun 22 11:01 .
drwxr-xr-x  3 root root  4096 Mar  7 14:12 ..
drwxrwxr-x  3 jonk jonk  4096 May 24 10:01 000SCRIPTS
drwxrwxr-x  2 jonk jonk  4096 Apr 14 13:47 00Port
drwxrwxr-x  2 jonk jonk  4096 Mar  7 15:27 111-script-library
drwx------  3 jonk jonk  4096 Apr 14 11:00 .adobe
drwx------  2 root root  4096 Jun 20 13:47 .aptitude
drwxrwxr-x  3 jonk jonk  4096 Apr 14 14:45 Audio
-rw-------  1 jonk jonk  6476 Jun 21 19:02 .bash_history
-rw-r--r--  1 jonk jonk   220 Mar  7 14:12 .bash_logout
-rw-r--r--  1 jonk jonk  3771 Mar  7 14:12 .bashrc
adobe, aptitude are hidden folders, and .bash_history, .bash_logout and .bashrc are hidden files
Code:
jonk@jonk-Len-usff:~$ ls -l
total 104
drwxrwxr-x  3 jonk jonk 4096 May 24 10:01 000SCRIPTS
drwxrwxr-x  2 jonk jonk 4096 Apr 14 13:47 00Port
drwxrwxr-x  2 jonk jonk 4096 Mar  7 15:27 111-script-library
drwxrwxr-x  3 jonk jonk 4096 Apr 14 14:45 Audio
Using ls -l you don't see them.

Good luck
 
Old 06-22-2020, 06:39 AM   #23
Roken
Member
 
Registered: Oct 2011
Location: Warrington, UK
Distribution: Arch local, Debian on VPS, several RPIs.
Posts: 300
Blog Entries: 1

Rep: Reputation: 55
Quote:
Originally Posted by GPGAgent View Post
Or through whatever filemangler you use, usually a View option.

CTRL-h will usually toggle hidden filed in the desktop file manager.
 
Old 06-23-2020, 01:10 AM   #24
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 19,872
Blog Entries: 12

Rep: Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053
Quote:
Originally Posted by GPGAgent View Post
Nobody has mentioned hidden files/folders, check for those.
Code:
ls -a
Code:
df
reports file system disk space usage, that includes hidden files.
 
Old 06-23-2020, 01:39 AM   #25
Roken
Member
 
Registered: Oct 2011
Location: Warrington, UK
Distribution: Arch local, Debian on VPS, several RPIs.
Posts: 300
Blog Entries: 1

Rep: Reputation: 55
Or

Code:
sudo du -ha / > ~/diskuse
Will list all files on the filesystem, with their sizes. You can then open ~/diskuse with something like LibreOffice Calc as a tab delimited file, and sort by size to see where all the diskspace is being used up starting with the largest files.

e.g. /var/log on my desktop is using almost 1Gb just by itself.
 
  


Reply



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
LXer: Raspberry Pi: Combine a Raspberry Pi with up to 4 Raspberry Pi Zeros for less than US$50 with the Cluster HAT LXer Syndicated Linux News 0 07-05-2019 12:03 PM
[SOLVED] full screen not really a full screen - why is that? linux-man Linux - Newbie 6 05-20-2018 08:21 AM
/tmp full - but not full ? turbo_acura Linux - Newbie 2 10-20-2010 08:20 AM
Help With Java Problem Please"""""""""""" suemcholan Linux - Newbie 1 04-02-2008 06:02 PM
Which distributions do not support --full-time for ls (ls --full-time)? GCS Linux - Distributions 0 07-28-2004 01:25 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware > Linux - Embedded & Single-board computer

All times are GMT -5. The time now is 02:14 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
Open Source Consulting | Domain Registration