ArgCV

  • Home
  • Code
  • Life
  • About
  • Guestbook
  • Gallery
  • RSS

Code

Code

How to keep the Ubuntu laptop on working

We may edit the configure file "/etc/systemd/logind.conf" and change one line from

#HandleLidSwitch=suspend

(more…)

By Yu, 4 years4 years ago
Code

Deploy a HDFS environment

This post will introduce some basic progress & configuration of deploying a HDFS cluster, and some error diagnosis.

Please see this post for a topic collection of distributed computing.

(more…)

By Yu, 4 years4 years ago
Code

Gracefully shutdown a http server in golang

To gracefully shutdown a http server requires a few steps.

The http library's serving function will block over there when getting started, until we call http.Server.Close(). As for us, we can invoke the starting function in a goroutine, and call close in another one.

(more…)

By Yu, 4 years4 years ago
octocat
Code

How to manage a repository on github without ssh key & password?

A simple way is to generate a personal access token instead.

(more…)

By Yu, 4 years4 years ago
Code

Detect the exists of methods in golang

Suppose we are trying to process a few interfaces, but not sure does a specific function exists.

(more…)

By Yu, 4 years4 years ago
Code

How to install Nvidia driver & CUDA?

It is more complex than ordinary packages, but still not hard.

(more…)

By Yu, 4 years4 years ago
Code

How to detect the exists of the Nvidia graphics cards

To detect the exists of the graphics cards on the computer, we may use command lshw. (more…)

By Yu, 4 years4 years ago
Code

Generate random bytes in golang

Need to generate a set of random bytes?

(more…)

By Yu, 4 years4 years ago
Code

When the monitor of your macOS alway frozen

Reset SMC or PRAM/NVRAM could helps.

In my data point, the second solution works for my MacBook Pro (15-inch, 2018).

(more…)

By Yu, 4 years4 years ago
Code

`type` could be the nightmare of bash completion on macOS

Every time I start a new session in my macOS, it will take a lot of time to initialize the session. After some survey, the key problem is the bash_completion.

(more…)

By Yu, 4 years2 years ago
Code

VIM: No protocol specified

After installed vim-gnome, every time I execute "sudo vim", it will print one line

$ sudo vim # doing something, and quit it
No protocol specified

(more…)

By Yu, 4 years4 years ago
Code

Install Node.js and Yarn

Node.jsĀ® is a JavaScript runtime built on Chrome's V8 JavaScript engine. It could used to create front-end project easily. Yarn is a fast dependency management tool. npm is great, but yarn could make the management better.

(more…)

By Yu, 4 years ago
Code

Install CUDA 9.2 on Ubuntu 18

CUDA is a parallel computing platform and application programming interface (API) model created by Nvidia. I am supposed to install this package in my system.

(more…)

By Yu, 4 years4 years ago

Posts navigation

Previous 1 2 3 … 16 Next
  • Home
  • About
  • Gallery
  • Guestbook
  • Privacy Policy
Hesmod | Developed by ThemeIsle, Revised by ArgCV