Posts
179
Following
26
Followers
383
Happy New Year to the new force of social media!
0
0
5

Continuing my Rust Rants :-)

It’s unfortunate that move is a keyword. As I write my little programs, I found that that’s a common function name I use. Now I need to come up with something else. adjust ?

4
0
0

There’s gotta be a better way…

use std::env;
use std::path::Path;

fn usage(arg: &String) {
    let path = Path::new(arg);

    println!("usage: {} a b", path.file_name().unwrap().to_str().unwrap());
}

fn main() {
    let args = env::args();

    if args.len() < 3 {
        usage(&args.collect::<Vec<String>>()[0]);
    }
}
0
0
1
Using the holiday break to learn Rust, I'm getting frustrated with Cargo. I mean, with C, I have a bunch of small programs that I use. But it seems that with Rust, to do the same, I have to make each one into a separate project, which I find overkill. Is there a easy way to make 100 little programs without making a 100 little projects???
0
2
6
That was fun. Added two more HDs to my workstation, but accidentally unplugged the power of one of the existing HDs. Thought the new HDs caused my existing md-raid1 to get screwy, and I had to re-add to the existing array as it was down a drive. I accidentally picked my external backup drive (blowing away all my backups). When I finally noticed, I shutdown the machine, plugging in the HD and on booting up, it picked the HD that was powered off as the main drive for the raid1! I spent a good half hour fixing all this. 😛
0
0
1

With 256G of RAM, should I even bother with adding swap?

0
0
1
I'm having way too much fun with my new server and having hot swap hard drives.
0
0
1
I have to say, the people at TechSupplyDirect are really eager to help out. Just got a call about my new Dell Server asking me if there's anything they can do to help me out, and if I have any issues, feel free to call them.
0
0
0
I was hoping to post this when we had had next year's venue locked down, but we are still not there yet. Anyway, Thanks for all the krill! https://lpc.events/blog/2022/index.php/2022/12/03/thats-a-wrap-thanks-everyone-for-linux-plumbers-2022/
0
8
12
My new server just came in today. I need to transfer the data from the old server to the new. This is going to be fun. I need to remove one of my old RAID HDs install it in the new server, get it working. Shutdown my VMs, transfer them to the new machine, and try to get them working there.

And I really have no idea what I'm doing.
1
0
2
Fun:
# echo 1 > /sys/kernel/tracing/options/func_stack_trace
# echo function > /sys/kernel/tracing/current_tracer
# time ./hackbench 5
(still waiting)
0
0
0
Is it just me, or is it harder to find motherboards, CPUs, and memory that are all compatible. I started looking for parts to build a new server and ended up just buying a refurbished Dell that had basically everything I was looking for and $500 cheaper than if I built it from parts.
0
0
2
Mastodon has made the NY Times.
https://nyti.ms/3hQbebV
0
1
1
My electric supplier notified me that my home usage is 200kwh over the average house of its size. This probably has to do with my ChromeOS build server that idles at 150w!
0
0
1
I'm trying to connect my mastodon android app to this account, but it's giving me an "Expired token" error. Anyone know how to fix it?
0
0
0

Created a new tool (WIP) That gives the output of something like this:

Total: 0.410332
  Max: 0.117048
  Min: 0.015632
  Avg: 0.041033
Count: 10
State: D
==> trace_event_raw_event_sched_switch+0xec
==> __traceiter_sched_switch+0x41
==> __schedule+0x4d3
==> schedule+0x5d
==> io_schedule+0x42
==> bit_wait_io+0xd
==> __wait_on_bit+0x4b
==> out_of_line_wait_on_bit+0x81
==> jbd2_journal_commit_transaction+0x15f1
==> kjournald2+0xa3
==> kthread+0xe9
==> ret_from_fork+0x22
Wakeup:
        ==> trace_event_raw_event_sched_wakeup_template+0x5f
        ==> try_to_wake_up+0x2e8
        ==> wake_bit_function+0x39
        ==> __wake_up_common+0x76
        ==> __wake_up_common_lock+0x6a
        ==> wake_up_bit+0x71
        ==> end_bio_bh_io_sync+0x26
        ==> clone_endio+0x103
        ==> blk_update_request+0x110
        ==> blk_mq_end_request+0x1a
        ==> blk_flush_complete_seq+0x15a
        ==> flush_end_io+0x1cf
        ==> scsi_end_request+0xdd
        ==> scsi_io_completion+0x46
        ==> blk_complete_reqs+0x40
        ==> __do_softirq+0x135

That shows the stack traces of all the places that were scheduled out in a S or D state and where it was woken up. Giving the total time of all instances of this location, as well as max, min, and average. And the number of times it was hit. There’s a surprising little number of these stacks.

Here’s the code. It depends on libtracefs 1.6.1.

0
0
4
Show older