-
Changing default command prompt and mounting fat32 in read/write mode.
I am running a highly customized harddrive install of Adriane Knoppix 7.2, and I have a few little annoyances I would like help with. I do nearly all of my offline computing from the Command line, and since the SBL screen reader Adriane uses in text mode speaks entire lines by default, it gets quite annoying to listen to it repeat knoppix@microknoppix followed by the path to the working directory every time I need it to read back the command I just typed. I know typing PS1=$ at the command line can be used to change the prompt to a stand-alone dollar sign, but I would like to make this change permanent instead of having to re-enter the command everytime I bring up the command line. I tried adding PS1=$ to the script I use to have vbetool turn off my monitor, but it doesn't seem to work there and I have no idea how to make the change automatic. My other problem is with mounting fat32 file systems. I do 99.9% of my file management from the command line and I normally mount external drives using the command: mount /dev/sdxn /media/sdxn where x is the drive letter and n is the partition number, and for all of my linux format drives(previously included ext3/4, now includes Btrfs and reiserfs) this works fine, but I have a FAT32 formatted SD card that I use for the rare occasions I need to use Windows PCs, and this command mounts it in read-only mode. The file manager provide by the Adriane-mount package can mount it in read-write mode, but it is annoying to have to leave the command line, launch the file manager, mount the SD card, exit the file manager and return to the command line every time I need to access the card and I realize I haven't mounted it since the last reboot. Is there a way I can mount this fat32 SD card in read-write mode from the command-line. Alternatively, is there a way to make the card automounted at boot?
-
Senior Member
registered user
Greetings, Jeffery.
In regards to PS1,
I would expect that if you defined PS1 to suit you in /etc/rc.local,
that should do it until you subsequently change it with another definition.
Is that not the case?
-
Best I can tell, my /etc/rc.local doesn't contain a existing PS1 definition, and apparently adding such a definition is more complicated than adding the line: PS1=$ on a blank line within the file. I'm no stranger to editing config files manually, but in this case, I am ignorant on how to edit the needed files to recieve the desired result.
Last edited by Jeffery Mewtamer; 02-25-2014 at 01:26 PM.
Reason: Glitch in quick replay deleting line breaks.
-
Senior Member
registered user
Just a suggestion
.
Greetings again, Jeffery.
I offer the following only if you feel comfortable making changes to your Knoppix.
You might edit /etc/rc.local with the command
Code:
sudo leafpad /etc/rc.local
to include a new single command line just before the 'exit 0' line, as follows:
Code:
#!/bin/bash
#
# rc.local
#
# Start local services after hardware detection
SERVICES="cups"
for i in $SERVICES; do
[ -x /etc/init.d/"$i" ] && /etc/init.d/"$i" start >/dev/null 2>&1
done
# PS1 re-definition command here.
exit 0
If you were to save and reboot with this /etc/rc.local, there should be no changes in your system.
If you use sudo leafpad /etc/rc.local to remove the initial '#' ahead of the command, and re-save
this changed /etc/rc.local, then I would expect this to change your PS1 for the remainder of this boot
and for subsequent re-boots until or unless your put the initial '#' back and reboot.
It's really not essential here, but it's good practice always to save an original configuration file
just in case somehow you goof up editing the original. With /etc/rc.local, since its permissions
are root:root, this means doing
Code:
sudo cp /etc/rc.local /etc/rc.local.orig
or something similar.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules

Dell PowerEdge R730 8Bay 64Gb 1x80Gb SSD 4x900Gb SAS 2x12c v4CPU 1100ws, 2GPUCbl
$660.00

Dell EMC PowerEdge R440 Xeon silver 4215 2.5GHz 16 GB ram 2x 550W PSU No HDD
$275.00

867959-B21 HPE ProLiant DL360 G10 CTO Server W/ 2x 865414-B21 1x 840140-001
$245.00

Dell PowerEdge R240 Intel Xeon E-2224 3.50GHz 8GB DDR4 ECC NO HDD 250W
$285.97

Gigabyte 4U AI Server 10x Nvidia GPU 2x Xeon Gold 6150 36 Core 2.7GHz DDR4 RAM
$1625.00

Dell PowerEdge R730XD 28 Core Server 2X Xeon E5-2680 V4 H730 32GB RAM No HDD
$378.93

Dell PowerEdge C4130 1U AI GPU Server | 2x E5-2690 v3 | 64gb Ram | 2x 1600W
$524.99

Dell PowerEdge C4130 1U AI GPU Server | 2x E5-2680 v3 | 32gb Ram | 2x 1600W
$409.99

Dell Poweredge R630 2x Intel Xeon E5-2650 v4 32GB RAM No Drives/OS Server
$292.50

Dell PowerEdge FX2s + 8x FC430 Blades 16x E5-2630v4 160 Cores Rails No PSU/RAM
$699.00