logs archiveIRC Archive / Freenode / #centos / 2015 / August / 3 / 1
bdonnahue
how can i get centos to pick its hostname from the dhcp dns server?
Sokel
bdonnahue: PTR records. If DNS has PTR records associated with the IP it's obtaining, it will assign itself that hostname
bdonnahue
ahh ok let me try that
dumb question but a ptr and reverse dns record are the same thing right?
fenrus02
https://en.wikipedia.org/wiki/Reverse_DNS_lookup
bdonnahue
thanks
so i created the reverse record and rebooted but the hostname is still localhost
billings
OneM_Industries: LVM?
OneM_Industries
I do not know what that means...
billings
No, I guess.
OneM_Industries
Ah, logical volume manager.
         

billings
if the unallocated space is right after an existing partition, its possible to "grow" the partition.
OneM_Industries
How would I do that?
billings
very carefully.
I suggest using a friendly tool like gparted
OneM_Industries
It is a secondary drive, so if I smoke it, no biggie.
This box is just a terminal.
No desktop.
DiscordianUK
parted is a CLI tool
OneM_Industries
So...how do I extend a partition?
DiscordianUK
lvm > lvresize
But I fear you don't have the skill to do it that way
AndyCap
OneM_Industries: is this an important box? do you have working backups?
OneM_Industries
Important: not really. Backups? No, as this is an empty HDD.
TrevorH
it's empty? then blow it away and make it LVM so you solve this for next time
OneM_Industries
Empty, but used.
AndyCap
OneM_Industries: oh, so it's not space on the same drive as your install?
OneM_Industries
Oh, no.
There are two drives in the box.
TrevorH
it's either empty or it isn't. Otherwise it's like being a little bit pregnant
OneM_Industries
One for the OS and one for the robot team.
DiscordianUK
The what?
OneM_Industries
This is the robot team drive, which I am cleaning off.
Again.
AndyCap
OneM_Industries: in "df" output, do you have /dev/mapper or /dev/sdX for the filesystems ?
DiscordianUK
I agree with TrevorH
OneM_Industries
/dev/mapper
It is empty, with this mystery partition and swap on it.
         

TrevorH
let's forget guesswork: pastebin the output of df -m, lvs, vgs, pvs and fdisk -l
OneM_Industries
TrevorH
and swapon -s
do you have any data that you want in that (parobably ntfs) partition on /dev/sdb?
OneM_Industries
http://pastebin.com/pH8NTf9y
Both drives were reformatted before use.
TrevorH
so the swap space on /dev/sdb5 is not in use
OneM_Industries
Mainly to get the hacked Russian version of Win 95 off of them.
TrevorH
I'd just delete all the partitions on /dev/sdb and make a new one, tag it type 0x8e then use pvcreate to make it an LVM PV, then either add that to your existing VG or make a new VG
OneM_Industries
Ok, how do I do that? rm -rf /dev/sdb?
TrevorH
fdisk
make sure you know what you are doing. fdisk is dangerous
OneM_Industries
(Action) has no clue what he is doing.
DiscordianUK
Step away from the computer
Is there someone in your company that does?
OneM_Industries
I may be a teen learning centos.
am*
So, no.
DiscordianUK
With a rather pretentious nick
OneM_Industries
Sorry.
Might as well change it, as I am nowhere else now...
OneMatt
Done.
DiscordianUK
Right , be careful with what you do
TrevorH
you can use fdisk fairly safely as it makes no changes until you do 'w<enter>' to write the changes and save it but you need to triple check that you are using the right disk drive
DiscordianUK
as said fdisk is destructive
OneMatt
Ah, I am using the right one.
As it said "omitting empty partition (5)" when I loaded sdb into it.
AndyCap
To be fair fdisk is not horribly destructive, until you begin using the new layout. and you have a backup of your old partition tables on pastebin now.
OneMatt
Oh, should probably save that link then.
Ok, so.
What do I do now?
m /dev/sdb1 sound good?
I mean d /dev/sdb1*
AndyCap
you are certain there is nothing in /media/HDD (/dev/sdb1) that you want to keep?
OneMatt
Yes.
AndyCap
OneMatt: have you unmounted it?
OneMatt
How would I unmount it?
AndyCap
in a root shell "umount /dev/sdb1"
TrevorH
@tutorial
centbot
An excellent guide for new users can be found here: http://linux.2038bug.com/rute-home.html While not official documentation, it contains information that should help you out.
OneMatt
Ah ha, empty drive.
So, n /dev/sdb1 sound good?
TrevorH
just n
AndyCap
OneMatt: you have deleted partitions 1 and 2 on sdb?
OneMatt
Yes.
AndyCap
OneMatt: as TrevorH said, just n <enter>
OneMatt
I did.
So, how do I tell it to make the last cylinder the end of the partition?
TrevorH
it asks
AndyCap
OneMatt: the defaults should be the whole disk
OneMatt
Ah, ok.
Yes!
It worked, thank you guys!
AndyCap
OneMatt: you're only half way there.
OneMatt
Oh?
Ah, now to format it.
How do I do that?
TrevorH
id you intend to use this for LVM then you should tag that new partition as type 0x8e
^ if
OneMatt
I repeat, how do I tag it as a certain type of format?
TrevorH
t in fdisk
« prev 1 2 3 4 5 6 next »