Re: [CentOS] Resize a VM: any risk involved ?
On 4/8/21 11:43 AM, Nicolas Kovacs wrote: # 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? Risk from a Virtual Machine perspective or just generally? One of the many operations I do often with VMs is "mess" with disks treating them as logical devices means I can add storage later, easy, when needed. In most cases I don't take the system down at all. "It just works". But there are always risks. If you're doing this manually, typos can bring down your system. Another part of your risk is using partitions. Partions, particular the "system" drive where rootfs is, can act oddly on Linux when it's live. It's not rare that you find the kernel refusing to do a "partprobe" on /dev/sda - which means you need a reboot for the kernel to see the new size of a partition. Next, your partition stuff is very limited - compared to so many other things you have in CentOS you should really avoid using partitions for anything - well, perhaps but that's about it. I use LVM on all my systems. To expand a system I simply add a new virtual disk, expand the VG, and then expand the filesystem using "lvexpand -r". It's painless and there are no risks of conflicts. LVM allows me to remove the disk later if need be - ie. the first disk size you added was 50GB but you realize a few months later that you calculated wrong as should have added 500GB. LVM allows you to add a new disk of 500GB, move everything from the old disk to the new, and then you can remove the new one - all without taking down the file system! It also comes with snapshot features for persistent backups. So at a risk of sounding like a broken record, don't use partitions. If risk is what you're focused on, there's a lot more risk using plain partitions vs. volume management. -- Regards Peter Larsen ___ CentOS mailing list CentOS@centos.org https://lists.centos.org/mailman/listinfo/centos
Re: [CentOS] nmcli
>how do I just remove the single ADDRESS I added as an alias ? not the whole thing ? You first remove all ipv4.addresses and then add the one you want. Then you save/activate. On Tue, Mar 30, 2021 at 4:41 PM Jerry Geis wrote: > under CentOS 7 - I use "alias" like eth1:0 for an alias network. Remove the > file restart network - and back to normal. Now I am trying to us > NetworkManager. > > I can 'add' the network fine. however - when I remove the network > nmcli connection delete "Wired connection 2" ipv4.addr 192.168.1.58/22 > > it remove BOTH address and removes the "Wired connection 2" config file - > and it reverts to DHCP not the other static address I had associated with > "Wired connection 2". > > how do I just remove the single ADDRESS I added as an alias ? not the whole > thing ? > > Thanks > > Jerry > ___ > 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] Question on nmcli CentOS 8
On 12/11/20 3:19 PM, Jerry Geis wrote: So now I need to "remove" both or all and add the 1 I want as static ? how do I do that? You have to remove the addresses and then add a new one. The ipv4.addresses is plural and additional when you set it. So to override you need to first remove all addresses, and add those you want to keep. Once you change method to manual, dhcp should be disabled. You do need to reactivate the connection once you've save the changes (same/typical nmcli procedure). -- Regards Peter Larsen ___ CentOS mailing list CentOS@centos.org https://lists.centos.org/mailman/listinfo/centos
Re: [CentOS] Question on server speed
On 8/5/19 3:00 PM, Jerry Geis wrote: > The keyboard is USB attached and the external SSD disk is USB attached. WHY? Why would you do that? What's the point of SSD if you reduce the speed to USB? Or just use an old mechanical drive instead. Any issue with that drive will show up as IO Wait - my presumption is that you expect to see that so you're not mentioning it but it's going to be extremely high. Remember, USB does not behave like SATA. And you may also find that the "max speed" in the specification is far from what you get out of your hardware. Use eSATA if you need it externally - not USB(3 or otherwise). -- Regards Peter Larsen ___ CentOS mailing list CentOS@centos.org https://lists.centos.org/mailman/listinfo/centos
Re: [CentOS] Thanks to every one
On 07/16/2017 12:30 PM, Andreas Benzler wrote: > - The firewall is placed in front of the cluster. > - After you have found a safe base for this, you freeze it. Sorry, but this statement really urks me in a wrong way. Why do you think a firewall is the ONLY part that needs to be provide security? That's the way I read this statement - that it doesn't matter anywhere else. In addition, the majority of attacks and compromises come from INSIDE the firewall - ie. the "wannacry" and similar attacks are all distributed via email, executed on a local workstation and it propagates from there - your external firewall is not even hit before your servers/cluster is scanned. Another aspect here is all the other stuff outside the kernel. Even if you do "yum update" frequently if you don't restart, there are several daemons and features of your system that doesn't get patched - the code is in memory and changing the disk has no effect at all. Bottom line is, I would not be proud of tripple digit single server uptimes. It simply tells me, I can find lots of ways in - not that you're running a rock solid setup. -- Regards, Peter Larsen ___ CentOS mailing list CentOS@centos.org https://lists.centos.org/mailman/listinfo/centos
Re: [CentOS] Free Redhat Linux (rhel) version 7.2
On 04/05/2016 11:55 AM, Always Learning wrote: > On Tue, 2016-04-05 at 08:16 -0700, Akemi Yagi wrote: > >> On Tue, Apr 5, 2016 at 8:08 AM, Always Learning <cen...@u64.u22.net> wrote: >> >>> What matters for the 'free' Red Hat software is ***ONLY*** Red Hat's >>> stated terms and conditions - definitely not what someone else has >>> put on a web site. >> Here is the link: >> >> https://developers.redhat.com/terms-and-conditions/ > > Thanks Akemi. > > I remind everyone, who is interested, that the absence of clearly > expressed definitions in > > https://developers.redhat.com/terms-and-conditions/ Actually, they are clearly defined here: http://www.redhat.com/licenses/GLOBAL_Appendix_one_English_20160111.pdf There are several (legal) documents at redhat.com that defines the details and conditions of any subscription. All of which has to be accepted as part of any subscription purchase. > (a) 'development purposes only' Which is defined as "“Development Purposes” means using the Software for the specific purpose of (a) individual developers writing software code, (b) single-user prototyping, quality assurance or testing and/or (c) demonstrating software or hardware that runs with or on the Software". > (b) 'a production installation' Which is defined as "“Production Purposes” means using the Software (a) in a production environment, (b) generally using live data and/or applications for a purpose other than Development Purposes, (c) for multi-user prototyping, quality assurance and testing and/or (d) for backup instances". (as per the appendix linked above). > and the lack of specific detail on > http://www.redhat.com/en/about/licenses (English version) Note the two links at the bottom of that page? You'll find the first appendix I linked above there. > means Red Hat would experience difficulties proving commercial loss, > other than a subscription fee loss. Now, do you think Red Hat has been selling subscriptions for 15+ years now without having to enforce their subscription agreements legally? > Even a subscription fee loss might be difficult for Red Hat to prove > taking into consideration Red Hat knew, or had good cause to know or was > recklessly indifferent to users comprehensively knowing precisely what > Red Hat meant by (a) and (b) above. Since you have to sign up to the subscription agreements before you subscribe, that's going to be a hard argument to win. As with everything in the US, every commercial contract is complex and full of "legalese" needed to defend against this type of argumentation ;) > A defendant could argue that Red Hat deliberately withheld that vital > knowledge from the unsuspecting users because Red Hat sought to exploit > users lack of full and detailed knowledge of the restrictions by > extorting money from users for commercial gain - a gain that would not > have been available to Red Hat if Red Hat had been a lot more specific > about the full extent of its limitations. > > One could legally argue that a criminal fraud was committed by obtaining > a free copy when the intention was to use it for conspicuous commercial > purposes. That argument is unlikely to apply to a person running their > own private system for non-commercial gain. > > Don't be frightened by Red Hat's statement "are required to pay the > applicable subscription fees, in addition to any and all other remedies > available to Red Hat under applicable law" > > "Other remedies" is fantasy. No one can possible legally commit > themselves to unknown and undefined "other remedies" as Red Hat's > lawyers should know. Seems like US of A style "bullying tactics" > intended to frighten people without access to affordable competent legal > advice. Not sure there's anything to be afraid of unless you're planning to use the developer subscription to maintain anything other than a developer system. The whole point of doing this by Red Hat (full disclosure - I'm a Red Hat employee) is to remove the barrier for the tons of FOSS developers out there who wants to develop on the platform they eventually deploy on. It's not meant to do anything other than that. As a whole, it shouldn't be hard for anyone to find and use RHEL for development purposes. > Me ? Well I am staying on C6 :-) That's why we have choice. This is not the Microsoft "everyone has to upgrade to Windows 10 like it or not" mentality. CentOS still has a lot of things to offer that you don't get from the free developer subscription. -- Regards Peter Larsen ___ CentOS mailing list CentOS@centos.org https://lists.centos.org/mailman/listinfo/centos
Re: [CentOS] Prevent network setup from changing the hostname
Make it a system connection instead of a user connection. Or give the host a static name on install and don't allow dhcp to override it. On 04/26/2015 07:26 PM, Robert Nichols wrote: How can I block network setup (via NetworkManager) from changing the machine's hostname whenever the network configuration changes? The problem: When my graphical login session starts, the xauth database gets an token that is labeled with the hostname at that time. If there is not yet a network connection, that will be localhost.localdomain. When a network connection is then made (my wireless connection needs the key from my login), the hostname changes. That breaks X session sharing because there is no xauth token that matches the current hostname. If I get a root shell with su -, commands launched from that shell cannot access the display. If I set up an ssh connection with ssh -X, I get a complaint about missing xauth data. On systems with an ONBOOT=yes network connection, there is no problem since the hostname is set before the X session starts. It's just when the hostname changes during the X session that there is a problem. I am running CentOS 6, fully updated. It's taken me a long time to track down the root cause of this problem. Now I just need a solution, preferably something less ham-fisted than xhost -. -- Regards Peter Larsen ___ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos
Re: [CentOS] Prevent network setup from changing the hostname
On 04/26/2015 08:25 PM, Robert Nichols wrote: On 04/26/2015 06:31 PM, Peter Larsen wrote: On 04/26/2015 07:26 PM, Robert Nichols wrote: How can I block network setup (via NetworkManager) from changing the machine's hostname whenever the network configuration changes? Make it a system connection instead of a user connection. Or give the host a static name on install and don't allow dhcp to override it. If you move networks and you are slaving your hostname to the DHCP offered name, then yes. But why do that? In /etc/dhcp/dhclient.conf you can configure exactly what you want and don't want from the server. There's a lot of options (man dhclient.conf is very helpful) but here's an example: send dhcp-client-identifier = hardware; request subnet-mask, broadcast-address, time-offset, routers, domain-search, domain-name, domain-name-servers, host-name; Just take out the host-name and you won't get (a new) one. You should however make sure that all your servers have a hostname configured before you do that. /etc/sysconfig/network is where you do that on CentOS6. Making my wireless connection a system connection increases the exposure of my WPA key and doesn't solve the problem of the network configuration changing, perhaps because I connected or disconnected an ethernet cable or the machine went to sleep on one WLAN and woke up on another. So your key isn't visible and only root can change a system device. A system device gets activated before the desktop. So you're not depending on having access to gconf etc. https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/6/html/Deployment_Guide/sec-User_and_System_Connections.html Do you know of a place I can set a static name that NetworkManager won't override? That would be ideal. I just doesn't make sense that the machine's internal relationships would depend on its external connections. See above. It's standard dhclient options. -- Regards Peter Larsen ___ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos
Re: [CentOS] Prevent network setup from changing the hostname
On 04/26/2015 09:19 PM, Robert Nichols wrote: On 04/26/2015 07:57 PM, Peter Larsen wrote: On 04/26/2015 08:25 PM, Robert Nichols wrote: On 04/26/2015 06:31 PM, Peter Larsen wrote: On 04/26/2015 07:26 PM, Robert Nichols wrote: How can I block network setup (via NetworkManager) from changing the machine's hostname whenever the network configuration changes? Make it a system connection instead of a user connection. Or give the host a static name on install and don't allow dhcp to override it. If you move networks and you are slaving your hostname to the DHCP offered name, then yes. But why do that? In /etc/dhcp/dhclient.conf you can configure exactly what you want and don't want from the server. There's a lot of options (man dhclient.conf is very helpful) but here's an example: NetworkManager invokes dhclient with a generated config file that ignores /etc/dhcp/dhclient.conf: dhclient ... -cf /var/run/nm-dhclient-wlan0.conf ... Well, true to a degree. Put the file in /etc/dhcp/dhclient.d and it'll be executed. Just make sure the script out-puts to stdout what goes into the dhclient configuration file used by NetworkManager. I ran across another report that suggests setting HOSTNAME to something other than localhost.localdomain in /etc/sysconfig/network would fix the problem. For the moment, that seems to be working. Strange - you may have a dhcp server that accepts host names from the clients - which of course would fit your use case. Just realize that not all dhcp servers are setup to be that lenient when it comes to preserving the host name picked by a client. But I am happy you got it working. -- Regards Peter Larsen ___ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos
Re: [CentOS] CentOS 7 /boot location
On 04/25/2015 01:43 PM, Devin Reade wrote: I noticed that (in a case with a two disk md mirror and lvm), the CentOS 7 installer is now placing /boot as the *last* partition on the disk. The position doesn't really matter. Some old bios needed the boot sector inside the LBA (first 1024 cylinders) - but the partition number doesn't equate to the sectors/cylinders you're assigning to them. So you may want to look at the actual addresses for each partition. I'm assuming that others are seeing this behavior. Does anyone know why it's now the last instead of the first? (Seems to work, though.) It should work. My guess is that you may have forgotten to set force primary on the boot partition. Again, grub doesn't care if it's a primary partition but they usually are created first if that matters to you. Devin ___ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos -- Regards Peter Larsen ___ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos
Re: [CentOS] turning off udev for eth0
On Tue, 2012-01-03 at 11:52 -0500, James B. Byrne wrote: I have set up a kvm host and configured a standard clone prototype for generating new guests. One persistent (pun intended) annoyance when cloning is the behaviour of udev with respect to the virtual network interface. The prototype is configured with just eth0 having a dedicated IP addr. When the prototype is cloned udev creates rules for both eth0 and eth1 in the clone. Because eth1 does not exist in the cloned guest one has to manually edit /etc/udev/rules.d/70-persistent-net.rules to get rid of the bogus entries and then restart the clone instance to have the changes take effect. All this does is return the new guest to the prototype eth0 configuration. Is there no way to alter udev's behaviour? Is udev even needed on a server system using virtual hardware? Altering the rules file not a big deal in itself but it adds needless busywork when setting up a new guest. Make sure the 70-persistent-net.rules is empty or doesn't contain any mappings in your template. This file is generated automatically when new hardware is discovered. So as long as the template doesn't contain it, you'll get it generated. The issue you'll find yourself in, however, is that you may discover the NICs in the wrong sequence so eth0 and eth1 gets swapped around for you. A better solution is to not use the MAC address but the bios location in 70-persistent-net.rules. If you do that, you can keep the file in the template. It's a very common problem. Another way is to have a %post script in KS or after initial startup as a VM, that fixes the file based on what the VM properties are. -- Best Regards Peter Larsen Wise words of the day: If you want to make God laugh, tell him about your plans. -- Woody Allen signature.asc Description: This is a digitally signed message part ___ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos
Re: [CentOS] centos server network speed check???
On Tue, 2011-03-29 at 05:13 +0800, mcclnx mcc wrote: we have several servers on same rack and servers are all inside firewall. Centos version from 4.X to 5.X. sometime the connection are very slow (compare to servers on other racks also inside firewall). we discuss with network engineer he ask us use ping and traceroute to check. Both tools response time are good but if we connect through application like Web browser, database, or DELL OPMN tool. The response time is very very slow. This situation normally last 4 to 5 hours then it back to normal. Does there has way to check real network response time so we can show to network engineer. Otherwise they always say no problem. miitool and ethtool Check that you're running at the right speed; sometimes bad cables will make the negotiation go bad. Sometimes you just connect to the wrong switch port. You may also note if the switch has hard-set values about the negotiation such as duplex settings. Make sure they match on both ends. You should be full duplex unless there's a very very good network reason not to. Lastly, check ifconfig output. Make sure there's no errors reported. If you have a high error count, it's a good bet the cable is bad or the sync settings are wrong. -- Best Regards Peter Larsen Wise words of the day: Showing up is 80% of life. -- Woody Allen signature.asc Description: This is a digitally signed message part ___ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos
Re: [CentOS] My new server
You get what you pay for. Yes ps/2 plugs are a thing of the past. Servers have for the last 5 or so years been usb only. Usually with a usb in the front as well as in the back. There are usb/ps2 converters but usb/mouse is very cheap. Your adapter would most likely cost the same or more. Lack of cd drive - sounds like you bought too cheap if you need that. Alternatively, pxe boot and install that way. One nic is also quite common. It depends on what you need the server to do. Regards Peter Larsen Timothy Murphy gayle...@eircom.net wrote: I bought a very cheap server yesterday - an HP ProLiant micro server for 160 euro (280 euro with 120 cashback, for some reason). But I was surprised when I opened the box to find it didn't come with keyboard or mouse, and doesn't have the old keyboard/mouse sockets, but requires USB versions. Is that the norm nowadays? Is it possible to convert the old keyboard/mouse plugs? Also there is no CD drive. But there are extensive instructions (on a CD!) about how to instal RHEL-5.5. I'm not complaining, just surprised. I got it as a fall-back for my aging server. The ProLiant is incredibly quiet, at least by comparison. One last thing - there is only one ethernet socket. This surprised me a little, as I can't see how it can be used as a server, without adding a second ethernet input? -- Timothy Murphy e-mail: gayleard /at/ eircom.net tel: +353-86-2336090, +353-1-2842366 s-mail: School of Mathematics, Trinity College, Dublin 2, Ireland ___ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos ___ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos
Re: [CentOS] Intel NIC
Have you considered looking into redhat enterprise virtualization? If you are interested I can put you in touch with a redhat rhev representative? Lamar Owen lo...@pari.edu wrote: On Saturday, December 18, 2010 04:19:25 am Gerhard Schneider wrote: The problem with VMWare Server is that it is a discontinued product for longer time and they don't provide us with a suitable replacement. VMware wants more people to get hooked on vSphere, so their 'suggested' VMware GSX^H^H^HServer replacement is vSphere Hypervisor, aka ESXi Free Edition. If you have suitable hardware you will get better performance with ESXi, but to get any of the more advanced functionality will require $$$ and vCenter Server. I have been looking at transitioning from VI3 (vCenter Server 2.5 and ESX 3.5) to something else; the price of vSphere 4 is simply too large to justify, and, while I have a valid license for vCenter Server Standard 4, I don't for ESX4 (it is a long story, and involves some rather precise timing of a difference in purchase and support dates for our original VI3 purchase, done in two phases). If I had a valid license for the full vSphere 4, I'm still not sure I'd run it, as the vCenter Server hardware requirements are steep. So I'm very seriously considering transitioning from VI3 to CentOS 6 KVM; for my situation it might be doable, but I have a lot to learn about KVM before I can think about it. Well, and CentOS 6 has to be out, too. I use many of the more advanced VI3 features, including vMotion, that means I really have to be careful. I'd want to cluster the hosts and have shared storage on my three onsite EMC Clariions. I'd like to 'RAID' the shared storage between two Clariions, actually, which ESX won't do, AFAIK. So a learning curve is up ahead Q1 or Q2 2011. ___ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos ___ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos