Details
-
Skillsgo, c++, unix, distributed systems.
-
Github
Joined devRant on 10/31/2016
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
-
This had me laughing out loud this morning, my wife just looked at me funny as I tried to explain it to her.2
-
So a couple of months ago I had some stability issues which seems to have caused Baloo go crazy and create an 1.7 exabyte index file. It was apparently mainly empty as zfs compressed it down to 535MB
Today I spent some time trying to reproduce the "issue" and turns out that wasn't that hard.
So this little program running on FreeBSD with a compressed (lz4) zfs dataset creates an 1.9 Exabyte large file, nicely compressed down to 45KB :)
#include <stdio.h>
#include <fcntl.h>
#include <unistd.h>
#include <sys/limits.h>
int main(int argc, char** argv) {
int fd = open("bigfile.lge", O_RDWR|O_CREAT, 0644);
for (int i = 0 ; i < 1000000000; i++) {
lseek(fd, INT_MAX, SEEK_CUR);
}
write(fd, " ",1);
close(fd);
}3 -
I was copying data from a failing zfs drive with rsync and I noticed that it spent a long time on the file ~/.local/share/Baloo/index
du -h index showed a 500ish MB file which didn't seem large enough to take this long.
I recalled that du shows disk usage, not file size and since I was using zfs compression they could be quite different.
so I added -A for apparent size:
du -hA index and it comes back with 1.7E
The file was 1.7 exabytes...6 -
Employees of companies that are so protective of their intellectual property that they don't allow any to be transfered outside of the workplace, how do you work from home?4
-
Is it just me or is python community's dependency management a bit unreliable?
I just can't seem to easily install any python programs without missing dependencies. Updates have caused libraries to become incompatible, which in turn causes the application that used to work to just produce a stack trace.
Is this the state of python or am I doing something wrong.3 -
Has OSS Projects build systems become more complicated lately?
I took a stab at building concourse ci on FreeBSD. It being written in go, I expected it to be rather straight forward but no.
To "compile" the web UI assets, yarn (an alternative nodejs package manager apparently) was required. (Are js and CSS really compile targets now?)
Installed yarn and ran yarn build, it complained about lessc not being installed, so ran yarn install lessc which then told me that I was running an unsupported operating system.
I can compile the actual consourse binary just fine, but without yarn doing it's thing the assets required for the web UI does not get compiled in and therefore doesn't work properly.
Maybe I compile the web UI assets in Linux, and cross compile my FreeBSD binary...5 -
For testing, I added an override environment variable in some C# code so I can set it in the projects debug properties when I run it.
Turns out that while it's possible to do this in C++ projects, MS decided that they don't want you to do that for C# projects as there are other ways that they want to do it.
So it's not possible to modify your environment for C# projects within visual studio.
*Bangs head against the wall and surrenders to the Microsoft way of doing things*1 -
When I got X up and running at 1am for the first time on my first computer, 486 SX 25MHz with 8 MB or ram.
The program SuperProbe is probably depicted now, but it got me up and running back then. -
I've gone from a "no early returns" guy to a "return as early as possible to maintain the happy path indented as much to the left as possible" guy.
Looks so much neater now. -
Devs who argue that their favourite language is the best and other are not good enough for anything. Different tools for different jobs dammit!4
-
Reading the source of a message queue system I'm planning on extending.
I don't see myself as a rockstar programmer or anything but the construction of arrays from hash tables, sorting those arrays and then a nested for loop to find matches really irks me. Luckily not on the critical message processing path but the stats collection thread. There are mutexes in play though that would probably delay processing a little bit when stats are collected. -
I'm logged into my box at home via ssh and coding in vim.... On the bus, using my phone.
I need more spare time, I get to sit down in front of my computer for maybe 1-2 hours a week.1