You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert
image/svg+xml Linux kernel map Constantine Shulyupin © 2007–2022 Constantine Shulyupin www.MakeLinux.net/kernel/map virtual logical electronics I/O memory CPU HI char devices HI subsystems address families sockets access protocols network interfaces networking Virtual File System block devices storage virtual memory memory access logical memory Page Allocator memory threads processes Scheduler int
ふと Linux ディストリビューションのユーザ認証周りについて気になって、その中でも特に UNIX パスワード認証について調べてみた。 UNIX パスワード認証というのは、Linux に限らず Unix 系のディストリビューションで広く採用されているパスワードを使った認証の仕組み。 特に、ログイン用のパスワードを暗号化 (ハッシュ化) した上でパスワードファイル (/etc/passwd) やシャドウパスワードファイル (/etc/shadow) に保存するところが特徴となっている。 UNIX パスワード認証は Unix 系の色々なディストリビューションでそれぞれ実装されている。 その中でも、今回は Linux ディストリビューションの Ubuntu 18.04 LTS について見ていく。 先に断っておくと、かなり長い。 注: この記事では、やっていることがハッシュ化でも manpage
Mackerelチームのエンジニアのid:itchynyです。 「mackerel-agentを入れるとloadavgが7時間ごとに上昇する」 先日、このような問い合わせを複数のお客さまから受けました。私も実験してみたところ、確かに再現しました。EC2 t2.microにmackerel-agentを入れて簡単なログ監視とプロセス監視を設定し、数日放置しました。 確かに、約7時間ごとにloadavgが上昇しています。この周期のcronの設定はしておらず、またmackerel-agent内部でも7時間ごとに行う処理はありません。しかし、プラグインを多く入れるほどloadavgのピーク値も上がります。 本エントリーでは、この現象の原因について説明します。 loadavgが上昇する原因を調べるには、まずloadavg自体がどう計算されているかを知る必要があります。 まずは、Linuxがloada
「カーネルのコードがよくわからない。Linuxカーネルに関する本を読んでもいまいちしっくりこない。」 から、「読めば理解できそう..!」 になるまでにやったことのまとめ。 はじめに 低レイヤの話がわかるようになりたかった。 カーネルの中身が知りたかった。 とりあえず本を読もうと思い詳解 Linuxカーネル 第3版を読んだが知識がなさ過ぎてよくわからない。 知らない用語だらけで都度調べればなんとなくはわかる気もするが、いまいち頭に入ってこない。 今思うとそもそもCPUの話なのかカーネルの話なのかさえよくわからない状態で読んでいたような気がする。 そんな状態を克服するためにやったことをまとめておく。 学習前 学習前の自分の知識はこんな感じだった。 知っていた データ構造とアルゴリズム 論理回路 C言語(研究室で数値計算に使える程度。構造体やポインタくらいならわかる。) よく知らなかった OSが
3. 自己紹介 - まぁまぁ MySQL でご飯食べてます - 一時期は Resource Monitoring や KVS にも 力入れてました - ネットワーク的には素人です - Linuxとハードウェアは嗜む程度 - disk I/O にはむかしから興味あります - その他 slideshare はこちら - http://www.slideshare.net/takanorisejima/ 4. 本日のお題 - kernel 新しくしたりすると、TCP的に意識したほ うが良い変化が見つかるので - 今日は、Webアプリケーションサーバの観点か ら、 connect(2) する際に気になる TIME_WAIT について、書いてみようかと思います - 有識者からのマサカリを、強く歓迎いたします 5. 最初に参考資料 - この二つの記事を読んでいただけば、それで概 ね良いと思うんですが
ps auxf を実行すると %CPU というカラムに CPU使用率 が表示される 見慣れた数値ではあるが、そもそも この数値はどういうロジックで計算されているんだったかな … と疑問が湧いた man を調べる man 1 ps では次のように説明されている %cpu %CPU プロセスの cpu 使用率は "##.#" というフォーマットである。 現在のところ CPU 使用率は、プロセスの生存期間中に 実行に利用した時間のパーセンテージで表される。 これを全部足しても 100% になることは (よほど幸運でなければ) ない。 (別名 pcpu)。 man は便利だが、今回は実装を知りたいのでソースを追うことにする ソースを追う 同じようなテーマを調べたブログは他にもあるかもしれないが、自分の中で手順を整理するためにも イチから書いてみよう。ソースの解説ではないので、ご了承を。 ディストリ
はじめに 前回に引き続き、ICMPまわりを追っていこうとしたら、大幅に脱線して、procファイルシステムに到着。 カーネルを少しいじりつつ、gdbの変数監視機能(watch)を利用することで、/proc/sys/net/ipv4/icmp_echo_ignore_allへの書き込みを監視することに成功した。 脱線のへの道のり ICMPエコーはicmp_echo関数によって処理される。 icmp_echo関数を見ると、net->ipv4.sysctl_icmp_echo_ignore_allフラグが立っていない場合は、 ICMPエコーを返さないようだ。 % cat net/ipv4/icmp.c [...] /* * Handle ICMP_ECHO ("ping") requests. * * RFC 1122: 3.2.2.6 MUST have an echo server that
はじめに これは Linux Advent Calendar 2016 の第 11 日目の記事です。Linux のタスクスケジューラーのソースコードや関連するドキュメントなどを読んで分かったことをまとめました。とても長いです・・・ はじめにスケジューラーのアーキテクチャと重要な概念を紹介し、その後はスケジューラーコアとシステムコールの実装について分かったことを延々と述べます。調べきれなかったことや分からなかったことは TODO に残したので、コメント欄とかツイッターで教えてもらえると嬉しいです。間違いの指摘も大歓迎です。 ちなみに私が読み始めたきっかけは、スケジューラーのアーキテクチャ、スケジューリングアルゴリズム、スケジューリングアルゴリズムの切り替え方、nice 値やプロセッサアフィニティがスケジューリングに及ぼす影響、プリエンプションの流れ、マルチプロセッサにおけるタスクのロードバラ
2015 - 10 - 31 Linux カーネルを読もうとするこれからの自分へのまとめ WIP Linux カーネル まとめ Linux カーネル 読むぞーって思ってたけどとりあえずクローンしたはいいけどこれどうしたらええんやろって思って 3 日坊主になってしまっていたので、最近 カーネル の話をよく聞くようになったからまた性懲りもなく Linux カーネル をクローンしました。 カーネル の入手方法 まず Git 入れてます。 sudo apt-get -y install git sudo yum -y install git おもむろに The Linux Kernel Archives を訪れます。 おぉ、サイト全体 SSL 化されてるんだな。 こういうサイト最近増えたよね。 PROTOCOL のリンクを踏むと HTTP だったら RFC に飛ばされたりします。うーん感慨深い。
4.0というか4/25時点のLinusツリーのHEAD リアルモードでbzImage(vmlinuz)の先頭から呼ばれる場合(LILOから呼ばれるときだっけ?) arch/x86/boot/header.S 圧縮されたカーネル(bzImage)の先頭にあるコード(setup.elf)のうちの一つ エントリポイント_startがある mainを呼ぶ arch/x86/boot/main.c mainがある いろいろハードウェアを初期化する go_to_protected_modeを呼ぶ arch/x86/boot/pm.c go_to_protected_modeがある setup_idtとかsetup_gdt等でプロテクトモードへ入る準備をする protected_mode_jumpでcode32_start(startup_32がある場所)へジャンプする startup_32は0x100
この記事はLinux Advent Calendar 2014の25日目ですヽ(=´▽`=)ノ 今回はLinux Kernel Hack入門編ということで入門的なことを書いてみたいと思います。 まず使用する環境ですけど最近出たばっかのFedora 21のWorkstationにしました。まあ、今回の内容的にはディストリビューションは問わないんですが、多くの人が馴染んでいるであろうfedora系というかパッケージマネージャがyumということでこれにしてみました。 自分は普段Arch Linuxなんですけど、こっちだとkernelのmake install時にちょっとしたスクリプトを書く必要があったりするのもあって、fedoraのほうが手軽かなというのもあります。 カーネルコード・リーディング ブラウザベースでコード・リーディング 読めるソースは大概メインラインのカーネルということになりますが
Kernel/VM Advent Calender 2013 7日目 カーネル/VMはておくれなすごい人がけっこう集って、ネタとか披露しているようです. 今年のAdvent Calenderも既に濃い内容が集っています. でも、私達パンピーにはカーネルとかちょっと難しすぎてそもそも カーネル/VMという主題自体敬遠しちゃう…… ということで本当にカーネルの第一歩をやってみよう、というのがこの記事です. 記事タイトルはえりっく氏(@siritori)から無断で肖ってます.ありがとうございます 今年の他の記事が高度な内容なので この記事が低レベル(低レイヤということでなく本当に程度が低いという意味で)ですいません. 普段からカーネル/VMに参加してる皆様、さようなら. カーネル/VM界隈わいわいしてておもしろそうだけど怖くて敬遠してる方々、こんにちは. 前置きはこのぐらいで本文行きます. 少々
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く