Skip to content

Instantly share code, notes, and snippets.

@yejingchen
yejingchen / main.rs
Last active December 21, 2020 17:21
tokio/io-ring hello world
use std::io;
use std::os::unix::io::AsRawFd;
use io_uring::IoUring;
use io_uring::opcode::{Write, types::Fd};
use thiserror::Error;
#[derive(Error, Debug)]
enum MyError {
From baf907e90f8172a4db5a8169b45d472c574e26f2 Mon Sep 17 00:00:00 2001
From: Ye Jingchen <ye.jingchen@gmail.com>
Date: Sat, 12 Dec 2020 01:20:01 +0800
Subject: [PATCH] add EnvironmentFile as config in systemd service
The provided connection string is suitable for default PostgreSQL
installation in Arch Linux.
---
PKGBUILD | 12 ++++++++----
prometheus-postgresql-exporter.conf | 1 +
@yejingchen
yejingchen / cclscompleter_stderrypdre8uw.log
Created December 4, 2020 17:19
YCM logs for watchdog issue
01:12:30 ccls initialize.cc:274 I initialize in directory /tmp/foo with uri file:///tmp/foo
01:12:30 ccls initialize.cc:297 I initializationOptions: {"compilationDatabaseCommand":"","compilationDatabaseDirectory":"","cache":{"directory":".ccls-cache","format":"binary","hierarchicalPath":false,"retainInMemory":2},"capabilities":{"documentOnTypeFormattingProvider":{"firstTriggerCharacter":"}","moreTriggerCharacter":[]},"foldingRangeProvider":true,"workspace":{"workspaceFolders":{"supported":true,"changeNotifications":true}}},"clang":{"excludeArgs":[],"extraArgs":[],"pathMappings":[],"resourceDir":""},"client":{"diagnosticsRelatedInformation":true,"hierarchicalDocumentSymbolSupport":true,"linkSupport":true,"snippetSupport":true},"codeLens":{"localVariables":true},"completion":{"caseSensitivity":2,"detailedLabel":true,"dropOldRequests":true,"duplicateOptional":true,"filterAndSort":true,"include":{"blacklist":[],"maxPathSize":30,"suffixWhitelist":[".h",".hpp",".hh",".inc"],"whitelist":[]},"maxN
2020-12-04 23:36:20,089 - INFO - Completion config: 50, detailing 10 candiates
2020-12-04 23:36:20,090 - INFO - Completion config: 50, detailing 10 candiates
2020-12-04 23:36:20,090 - INFO - Completion config: 50, detailing 10 candiates
2020-12-04 23:36:20,090 - INFO - Completion config: 50, detailing 10 candiates
2020-12-04 23:36:20,150 - INFO - Received ready request
2020-12-04 23:36:20,154 - INFO - Received signature help available request
2020-12-04 23:36:20,158 - INFO - Received event notification
2020-12-04 23:36:20,163 - INFO - Received event notification
2020-12-04 23:36:20,163 - INFO - Adding buffer identifiers for file: /tmp/a.c
2020-12-04 23:36:20,179 - INFO - No Clangd executable found in /home/yjc/.vim/plugged/YouCompleteMe/third_party/ycmd/third_party/clangd/output/bin
@yejingchen
yejingchen / vpnfailure.log
Last active April 26, 2016 08:07
Arch cannot connect to VPN, this is the journal of NetworkManager
4月 25 20:05:18 yjc-y460 NetworkManager[7116]: <info> Starting VPN service 'l2tp'...
4月 25 20:05:18 yjc-y460 NetworkManager[7116]: <info> VPN service 'l2tp' started (org.freedesktop.NetworkManager.l2tp), PID 11964
4月 25 20:05:18 yjc-y460 NetworkManager[7116]: <info> VPN service 'l2tp' appeared; activating connections
4月 25 20:05:18 yjc-y460 NetworkManager[7116]: ** Message: Use '10.5.1.9' as gateway
4月 25 20:05:18 yjc-y460 NetworkManager[7116]: ** Message: Check port 1701
4月 25 20:05:18 yjc-y460 NetworkManager[7116]: ** Message: Can't bind to port 1701
4月 25 20:05:18 yjc-y460 NetworkManager[7116]: ** (nm-l2tp-service:11964): WARNING **: Port 1701 is busy, use ephemeral.
4月 25 20:05:18 yjc-y460 NetworkManager[7116]: ** Message: ipsec 启用标志:(null)
4月 25 20:05:18 yjc-y460 NetworkManager[7116]: ** Message: xl2tpd started with pid 11968
4月 25 20:05:18 yjc-y460 NetworkManager[7116]: <info> VPN connection 'zju' (ConnectInteractive) reply received.
@yejingchen
yejingchen / fedora-22-to-23-boot-loop-journal.txt
Created November 12, 2015 01:57
Fedora 22 to 23 boot loop journal
This file has been truncated, but you can view the full file.
-- Logs begin at 五 2015-09-11 20:16:24 CST, end at 四 2015-11-12 09:53:19 CST. --
11月 06 16:15:27 yejingchen-y460 systemd-journal[158]: Runtime journal (/run/log/journal/) is currently using 8.0M.
Maximum allowed usage is set to 187.5M.
Leaving at least 281.3M free (of currently available 1.8G of space).
Enforced usage limit is thus 187.5M.
11月 06 16:15:27 yejingchen-y460 systemd-journal[158]: Runtime journal (/run/log/journal/) is currently using 8.0M.
Maximum allowed usage is set to 187.5M.
Leaving at least 281.3M free (of currently available 1.8G of space).
Enforced usage limit is thus 187.5M.
11月 06 16:15:27 yejingchen-y460 kernel: microcode: CPU0 microcode updated early to re