Re: [CentOS] Automatic clean /tmp folder

2021-04-08 Thread Jon LaBadie

On Thu, Apr 08, 2021 at 01:09:57PM +, Gestió Servidors wrote:

With these files I supposed that a file with more than 10 days in /tmp
would be automatically deleted, but today I have found some files/folders
with more than 10 days.

What I have done wrong?


The test is on access time, not modification. Have they been read in the last 
10 days?


And note that a GUI file manager might attempt to read every file in a
directory in order to determine its type and display the correct icon.


I have check my /tmp folder with "find ./ -atime +10d" and there are
some folders that appears as "accessed" more than 10 days ago... so I
don't understand why automatic deletion system has not deleted them.

Thanks.


Typically directories are not deleted if not empty.
Do those folders contain items that were accessed more recently?


--
Jon H. LaBadie  j...@labadie.us

___
CentOS mailing list
CentOS@centos.org
https://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] Resize a VM: any risk involved ?

2021-04-08 Thread R C
You could make a copy of the VM, and  see if you can resize things  with 
the copy and see if it breaks?


On 4/8/21 9:43 AM, Nicolas Kovacs wrote:

Hi,

I'm currently fiddling with KVM, Proxmox and various VMs.

I setup a very basic VM with a manual (fdisk) partitioning scheme: one /boot
partition, one swap partition, and one root partition, the latter being the
last partition and thus expandable).

I'm starting with a reduced disk size (6 GB in total) and a minimal
installation. The idea behind this approach is that I can clone this minimal VM
and then eventually expand it to fit my needs.

Here's how I expand the available disk size.

First I increase the virtual disk in the hypervisor.

Then I fire up the VM and do the following:

# yum install cloud-utils-growpart
# lsblk
# growpart -v /dev/sda 3
# resize2fs /dev/sda3

Now here's my question (finally): is there any risk involved in this sort of
operation? Or can it be performed on a production system without having to
worry about data loss?

Cheers from the sunny South of France,

Niki


___
CentOS mailing list
CentOS@centos.org
https://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] Resize a VM: any risk involved ?

2021-04-08 Thread Fred
I'm using VirtualBox for a few VMs, the biggest one is a Ubuntu 20.04 that
ocassionally grows too small, so I use virtualbox tools to enlarge the disk
then boot up something that h as gparted in it and use gparted to
stretch/move partitions.

Not being familiar with (i.e., not having used) KVM I can't say what's the
best way, but it seems to me that gparted would be easier than the steps
you described., once you've changed the partition size.

On Thu, Apr 8, 2021 at 11:43 AM Nicolas Kovacs  wrote:

> Hi,
>
> I'm currently fiddling with KVM, Proxmox and various VMs.
>
> I setup a very basic VM with a manual (fdisk) partitioning scheme: one
> /boot
> partition, one swap partition, and one root partition, the latter being the
> last partition and thus expandable).
>
> I'm starting with a reduced disk size (6 GB in total) and a minimal
> installation. The idea behind this approach is that I can clone this
> minimal VM
> and then eventually expand it to fit my needs.
>
> Here's how I expand the available disk size.
>
> First I increase the virtual disk in the hypervisor.
>
> Then I fire up the VM and do the following:
>
> # yum install cloud-utils-growpart
> # lsblk
> # growpart -v /dev/sda 3
> # resize2fs /dev/sda3
>
> Now here's my question (finally): is there any risk involved in this sort
> of
> operation? Or can it be performed on a production system without having to
> worry about data loss?
>
> Cheers from the sunny South of France,
>
> Niki
>
> --
> Microlinux - Solutions informatiques durables
> 7, place de l'église - 30730 Montpezat
> Site : https://www.microlinux.fr
> Blog : https://blog.microlinux.fr
> Mail : i...@microlinux.fr
> Tél. : 04 66 63 10 32
> Mob. : 06 51 80 12 12
> ___
> CentOS mailing list
> CentOS@centos.org
> https://lists.centos.org/mailman/listinfo/centos
>
___
CentOS mailing list
CentOS@centos.org
https://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] Resize a VM: any risk involved ?

2021-04-08 Thread Valeri Galtsev


On 4/8/2021 4:49 PM, Nicolas Kovacs wrote:

Le 08/04/2021 à 18:35, Simon Matter a écrit :

BTW, are you not using XFS these days?


I remember the first Linux HOWTO I used to start with xfs was entitled: \

XFS: Linux on steroids

;-)

Valeri


Been using ext4 for ages.

Force of habit, I guess. I have yet to find a reason to move to something
different.

Niki


___
CentOS mailing list
CentOS@centos.org
https://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] Resize a VM: any risk involved ?

2021-04-08 Thread Nicolas Kovacs
Le 08/04/2021 à 18:35, Simon Matter a écrit :
> BTW, are you not using XFS these days?

Been using ext4 for ages.

Force of habit, I guess. I have yet to find a reason to move to something
different.

Niki

-- 
Microlinux - Solutions informatiques durables
7, place de l'église - 30730 Montpezat
Site : https://www.microlinux.fr
Blog : https://blog.microlinux.fr
Mail : i...@microlinux.fr
Tél. : 04 66 63 10 32
Mob. : 06 51 80 12 12
___
CentOS mailing list
CentOS@centos.org
https://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] CentOS 8

2021-04-08 Thread Tony Schreiner
On Thu, Apr 8, 2021 at 2:33 PM Nicolas Kovacs  wrote:

> Le 08/04/2021 à 18:58, Steve Clark via CentOS a écrit :
> > How do I allow root log in on GDM.
>
> tl;dr: you don't.
>
> Log in as a non-root user, and when you do need root, either open up a
> terminal
> and use 'su -' or (even better) setup your user by making your user a
> member of
> the wheel group and then use sudo.
>
> Logging in to a GUI as root is *BAD* practice.
>
> Cheers,
>
> Niki
>
>
>
That said - you can do it, by clicking on "Not listed?" and typing root
into the user field.
___
CentOS mailing list
CentOS@centos.org
https://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] CentOS 8

2021-04-08 Thread Nicolas Kovacs
Le 08/04/2021 à 18:58, Steve Clark via CentOS a écrit :
> How do I allow root log in on GDM.

tl;dr: you don't.

Log in as a non-root user, and when you do need root, either open up a terminal
and use 'su -' or (even better) setup your user by making your user a member of
the wheel group and then use sudo.

Logging in to a GUI as root is *BAD* practice.

Cheers,

Niki

-- 
Microlinux - Solutions informatiques durables
7, place de l'église - 30730 Montpezat
Site : https://www.microlinux.fr
Blog : https://blog.microlinux.fr
Mail : i...@microlinux.fr
Tél. : 04 66 63 10 32
Mob. : 06 51 80 12 12
___
CentOS mailing list
CentOS@centos.org
https://lists.centos.org/mailman/listinfo/centos


[CentOS] CentOS 8

2021-04-08 Thread Steve Clark via CentOS

Hello,

How do I allow root log in on GDM.
The only people that have access are admins - so I am not worried about
someone screwing things up.

Thanks,

--
Stephen Clark

Email Confidentiality Notice: The information contained in this transmission 
may contain privileged and confidential and/or protected health information 
(PHI) and may be subject to protection under the law, including the Health 
Insurance Portability and Accountability Act of 1996, as amended (HIPAA). This 
transmission is intended for the sole use of the individual or entity to whom 
it is addressed. If you are not the intended recipient, you are notified that 
any use, dissemination, distribution, printing or copying of this transmission 
is strictly prohibited and may subject you to criminal or civil penalties. If 
you have received this transmission in error, please contact the sender 
immediately and delete this email and any attachments from any computer. Vaso 
Corporation and its subsidiary companies are not responsible for data leaks 
that result from email messages received that contain privileged and 
confidential and/or protected health information (PHI).
___
CentOS mailing list
CentOS@centos.org
https://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] Resize a VM: any risk involved ?

2021-04-08 Thread Simon Matter
> Hi,
>
> I'm currently fiddling with KVM, Proxmox and various VMs.
>
> I setup a very basic VM with a manual (fdisk) partitioning scheme: one
> /boot
> partition, one swap partition, and one root partition, the latter being
> the
> last partition and thus expandable).
>
> I'm starting with a reduced disk size (6 GB in total) and a minimal
> installation. The idea behind this approach is that I can clone this
> minimal VM
> and then eventually expand it to fit my needs.
>
> Here's how I expand the available disk size.
>
> First I increase the virtual disk in the hypervisor.
>
> Then I fire up the VM and do the following:
>
> # yum install cloud-utils-growpart
> # lsblk
> # growpart -v /dev/sda 3
> # resize2fs /dev/sda3
>
> Now here's my question (finally): is there any risk involved in this sort
> of
> operation? Or can it be performed on a production system without having to
> worry about data loss?

I'm often doing something similar but *not* with partitions. I have either
disk images or logical volumes on the KVM host which I grow and then use
"virsh blockresize" to adjust size. Then on the guest I only have to
resize the filesystem or in case using LVM on the guest, first "lvextend"
and then resize the filesystem.

Fiddling with partitions without the ability to reboot always scares me a
bit. That's why I prefer not to so it and therefore I have not used
"growpart".

BTW, are you not using XFS these days?

Regards,
Simon

___
CentOS mailing list
CentOS@centos.org
https://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] Resize a VM: any risk involved ?

2021-04-08 Thread Leon Fauster via CentOS

On 08.04.21 17:43, Nicolas Kovacs wrote:

Hi,

I'm currently fiddling with KVM, Proxmox and various VMs.

I setup a very basic VM with a manual (fdisk) partitioning scheme: one /boot
partition, one swap partition, and one root partition, the latter being the
last partition and thus expandable).

I'm starting with a reduced disk size (6 GB in total) and a minimal
installation. The idea behind this approach is that I can clone this minimal VM
and then eventually expand it to fit my needs.

Here's how I expand the available disk size.

First I increase the virtual disk in the hypervisor.

Then I fire up the VM and do the following:

# yum install cloud-utils-growpart
# lsblk
# growpart -v /dev/sda 3
# resize2fs /dev/sda3

Now here's my question (finally): is there any risk involved in this sort of
operation? Or can it be performed on a production system without having to
worry about data loss?


Just a hint - man virt-resize

--
Leon





___
CentOS mailing list
CentOS@centos.org
https://lists.centos.org/mailman/listinfo/centos


[CentOS] Resize a VM: any risk involved ?

2021-04-08 Thread Nicolas Kovacs
Hi,

I'm currently fiddling with KVM, Proxmox and various VMs.

I setup a very basic VM with a manual (fdisk) partitioning scheme: one /boot
partition, one swap partition, and one root partition, the latter being the
last partition and thus expandable).

I'm starting with a reduced disk size (6 GB in total) and a minimal
installation. The idea behind this approach is that I can clone this minimal VM
and then eventually expand it to fit my needs.

Here's how I expand the available disk size.

First I increase the virtual disk in the hypervisor.

Then I fire up the VM and do the following:

# yum install cloud-utils-growpart
# lsblk
# growpart -v /dev/sda 3
# resize2fs /dev/sda3

Now here's my question (finally): is there any risk involved in this sort of
operation? Or can it be performed on a production system without having to
worry about data loss?

Cheers from the sunny South of France,

Niki

-- 
Microlinux - Solutions informatiques durables
7, place de l'église - 30730 Montpezat
Site : https://www.microlinux.fr
Blog : https://blog.microlinux.fr
Mail : i...@microlinux.fr
Tél. : 04 66 63 10 32
Mob. : 06 51 80 12 12
___
CentOS mailing list
CentOS@centos.org
https://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] Booting from an ISO file in a XFS /boot

2021-04-08 Thread Gestió Servidors
> Just guessing - loading the grub module for xfs is missing?


Also, I have test adding "insmod xfs" in the "menuentry" section of my "iPXE" 
boot option, but result is the same...
___
CentOS mailing list
CentOS@centos.org
https://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] Automatic clean /tmp folder

2021-04-08 Thread Gestió Servidors
>>> With these files I supposed that a file with more than 10 days in /tmp

>>> would be automatically deleted, but today I have found some files/folders

>>> with more than 10 days.

>>>

>>> What I have done wrong?

>>

>> The test is on access time, not modification. Have they been read in the 
>> last 10 days?

>

>And note that a GUI file manager might attempt to read every file in a

>directory in order to determine its type and display the correct icon.


I have check my /tmp folder with "find ./ -atime +10d" and there are some 
folders that appears as "accessed" more than 10 days ago... so I don't 
understand why automatic deletion system has not deleted them.

Thanks.

___
CentOS mailing list
CentOS@centos.org
https://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] Booting from an ISO file in a XFS /boot partition

2021-04-08 Thread Leon Fauster via CentOS

On 08.04.21 11:16, Gestió Servidors wrote:

Hi,

I want to boot with a customized iPXE iso boot file from my GRUB2 menu. My 
system is running CentOS-7, with /boot formated as XFS filesystem. After 
copying my iPXE.iso into /boot, I have created a custom GRUB2 file in 
/etc/grub.d/40_custom like this:

menuentry "iPXE" {
set isofile="/ipxe.iso"
loopback loop (hd0,1)$isofile
linux16 (loop)/ipxe.lkrn
}

After regenerating grub2.cfg with "grub2-mkconfig -o /etc/grub2.cfg ,  I have rebooted my 
system, I have chosen "iPXE" entry, but system doesn't boot. I receive this error:
error: file '/ipxe.iso' not found.
Starting /ipxe.iso...
error: no server is specified.
Press any key to continue...

However, in another similar system that runs /boot in EXT4 filesystem, that ISO 
file boots perfectly with the same configuration, so it seems the problem is 
with XFS.

Could you help me?



Just guessing - loading the grub module for xfs is missing?

--
Leon

___
CentOS mailing list
CentOS@centos.org
https://lists.centos.org/mailman/listinfo/centos


[CentOS] Booting from an ISO file in a XFS /boot partition

2021-04-08 Thread Gestió Servidors
Hi,

I want to boot with a customized iPXE iso boot file from my GRUB2 menu. My 
system is running CentOS-7, with /boot formated as XFS filesystem. After 
copying my iPXE.iso into /boot, I have created a custom GRUB2 file in 
/etc/grub.d/40_custom like this:

menuentry "iPXE" {
   set isofile="/ipxe.iso"
   loopback loop (hd0,1)$isofile
   linux16 (loop)/ipxe.lkrn
}

After regenerating grub2.cfg with "grub2-mkconfig -o /etc/grub2.cfg ,  I have 
rebooted my system, I have chosen "iPXE" entry, but system doesn't boot. I 
receive this error:
error: file '/ipxe.iso' not found.
Starting /ipxe.iso...
error: no server is specified.
Press any key to continue...

However, in another similar system that runs /boot in EXT4 filesystem, that ISO 
file boots perfectly with the same configuration, so it seems the problem is 
with XFS.

Could you help me?

Thanks.
___
CentOS mailing list
CentOS@centos.org
https://lists.centos.org/mailman/listinfo/centos