Tiny Core Linux

Tiny Core Base => TCB Q&A Forum => Topic started by: DesobedecoMinhaImaginacao on December 13, 2023, 02:51:39 PM

Title: Hide tce-load command output
Post by: DesobedecoMinhaImaginacao on December 13, 2023, 02:51:39 PM
A command that doesn't work:

tce-load -il compiletc &> /dev/null
Title: Re: Hide tce-load command output
Post by: Rich on December 13, 2023, 04:06:28 PM
Hi DesobedecoMinhaImaginacao
Does it work like this:
Code: [Select]
tce-load -il compiletc 2>&1 > /dev/null
Title: Re: Hide tce-load command output
Post by: DesobedecoMinhaImaginacao on December 14, 2023, 05:12:28 PM
It didn't work here. :D ;D
Title: Re: Hide tce-load command output
Post by: Rich on December 14, 2023, 05:38:19 PM
Hi DesobedecoMinhaImaginacao
What didn't work? Your question sounds like you want
the command to be quiet. The command is quiet the
way it is written.

It the extension didn't load, you probably don't have it
downloaded:
Code: [Select]
tc@E310:~$ tce-load
Version 10.1
Usage: tce-load [ -i -w -wi -wo -wil -ic -wic -wicl]{s} extensions
  -i   Loads local extension
  -w   Download extension only
  -wi  Download and install extension
  -wo  Download and create an ondemand item
  Adding -c to any -i option will force a one time copy to file system
  Adding -l to any -i option indicates load only - do not update onboot or ondemand
  Adding -s to any option will suppress OK message used by apps GUI

Example usage:
 Load local extension:
   tce-load -i /mnt/hda1/tce/optional/nano.tcz
 Download into tce/optional directory, updates OnBoot and installs:
   tce-load -w -i nano.tcz
 Download only into tce/optional directory:
   tce-load -w nano.tcz
tc@E310:~$

Your command assumes the extension is downloaded.
If it isn't, try this:
Code: [Select]
tce-load -wil compiletc 2>&1 > /dev/null
Title: Re: Hide tce-load command output
Post by: DesobedecoMinhaImaginacao on December 15, 2023, 08:30:42 AM
The command below:

tce-load -il bc 2>&1 > /dev/null

Displays the installation output.  I really wish the command would be quiet.

TC 14.x x86_64
Title: Re: Hide tce-load command output
Post by: Rich on December 15, 2023, 09:09:25 AM
Hi DesobedecoMinhaImaginacao
Sorry, I can't reproduce your issue. I copied/pasted your
command on a  TC 14.x x86_64  system and it worked
perfectly.

... code]tc@E310:~$ tce-load

 ----- Snip -----

  Adding -s to any option will suppress OK message used by apps GUI

 ----- Snip -----
tc@E310:~$[/code] ...

See if it works like this for you:
Code: [Select]
tce-load -ils bc 2>&1 > /dev/null
Title: Re: Hide tce-load command output
Post by: DesobedecoMinhaImaginacao on December 15, 2023, 01:31:46 PM
The OK message has indeed been suppressed, but the loop-initiated message remains to be hidden
Title: Re: Hide tce-load command output
Post by: Rich on December 15, 2023, 01:42:46 PM
Hi DesobedecoMinhaImaginacao
I'm afraid I'm out of ideas. Base on the information you've
provided, I don't see why my example would not work.
Title: Re: Hide tce-load command output
Post by: Rich on December 15, 2023, 10:08:03 PM
Hi DesobedecoMinhaImaginacao
Are you running this on bare metal or virtual machine?
Title: Re: Hide tce-load command output
Post by: curaga on December 16, 2023, 01:38:56 AM
What loop initiated message? The kernel one, loop changed size to blahblah? That's not from the command, that's from the kernel, and you can hide it on the ttys by adjusting the kernel's log level (try the boot param "quiet").
Title: Re: Hide tce-load command output
Post by: DesobedecoMinhaImaginacao on December 17, 2023, 02:25:00 PM
Run on bare metal.

It remains to hide the message generated by the command on tce-load:

sudo mount /etc/sysconfig/tcedir/optional/bc.tcz /tmp/tcloop/bc -tsquashfs -o loop,ro 2>&1
Title: Re: Hide tce-load command output
Post by: CentralWare on December 21, 2023, 01:59:26 AM
IF memory serves, to hide kernel messages you can simply adjust "printk" levels.
Read the current levels (cat /proc/sys/kernel/printk) - let's assume they're 3 4 5 6 for this example.
Write the levels to 1 1 1 1, run your commands you want there to be no system messages, then re-write the levels back to where they started.
* Note: I don't remember if 1 1 1 1 is the lowest or 0 0 0 0

sudo dmesg -n [LEVEL] can also affect what you receive on the console