<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>masami256</author_name>
  <author_url>https://blog.hatena.ne.jp/masami256/</author_url>
  <blog_title>φ(・・*)ゞ ｳｰﾝ　カーネルとか弄ったりのメモ</blog_title>
  <blog_url>https://kernhack.hatenablog.com/</blog_url>
  <categories>
    <anon>kernel</anon>
    <anon>linux</anon>
  </categories>
  <description>Linuxで名前空間に関して設定できるのはclone(2)、unshare(2)、setns(2)で、このうち実行中のプロセスの名前空間を変更できるのは後者の2個なんですが、カーネル側ではkernel/nsproxy.cにあるswitch_task_namespaces()が実際の処理を行ってます。そんなわけでこの辺りのコードを見てみます。 まず、switch_task_namespaces()を呼んでいる箇所ですが以下の4つがありました unshareシステムコールの実行時 setnsシステムコールの実行時 exitシステムコール実行時 copy_process()のエラー処理 このうち1、…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fkernhack.hatenablog.com%2Fentry%2F2014%2F08%2F14%2F004207&quot; title=&quot;Linux:実行中プロセスの名前空間切り替え - φ(・・*)ゞ ｳｰﾝ　カーネルとか弄ったりのメモ&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url>http://ecx.images-amazon.com/images/I/51hm94xagHL.jpg</image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2014-08-14 00:42:07</published>
  <title>Linux:実行中プロセスの名前空間切り替え</title>
  <type>rich</type>
  <url>https://kernhack.hatenablog.com/entry/2014/08/14/004207</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
