Skip to content

Convert UTC to MDT via MySQL

I’m having trouble changing my queries to use the my current MDT timezone. The server and MySQL are UTC When I try to run CONVERT_TZ() to US/Mountain, my time is way off. Returns 2016-08-08 18:00:00 Not sure what I’m doing wrong here. Answer Instead of curdate, you should use now like you did in y…

How to repeat a dash (hyphen) in shell

How can I repeat the character – n times in shell? I have read and tried this, but this does not work for -. It throws error invalid option. Below is the exact command that I used: Original posted line: printf ‘-%0.s’ {1..100} I also tried escaping – by putting a but in that case it r…

Run bash whiptail script after login with sudo

I’m creating a virtual machine configuration script using whiptail that I’d like to have automatically start after the user logs in. The thing is, that I don’t want the user to be root, however because the user will need to be able to change things like hostname, ip address, add directories,…

About the memory layout of programs in Linux

I have some questions about the memory layout of a program in Linux. I know from various sources (I’m reading “Programming from the Ground Up”) that each section is loaded into it’s own region of memory. The text section loads first at virtual address 0x8048000, the data section is loa…

Embedded Qt Mouse Pointer Not Showing Up

I’ve got a bit of an interesting problem here. There are plenty of threads I’ve found where people are working to hide or get rid of a cursor on an embedded Qt GUI…but I’m trying to get a cursor to show up on an embedded Qt GUI. I inherited a project that was ‘finished’ som…