diff --git a/.gitignore b/.gitignore index 406061feb7db..ce4c0da83401 100644 --- a/.gitignore +++ b/.gitignore @@ -30,3 +30,8 @@ codekit-config.json .sass-cache _asset_bundler_cache _site + + +_posts/.ztr-directory + +.obsidian/* diff --git a/CNAME b/CNAME new file mode 100644 index 000000000000..e72aab8057f8 --- /dev/null +++ b/CNAME @@ -0,0 +1 @@ +jongminlee.me \ No newline at end of file diff --git a/Gemfile b/Gemfile index 3be9c3cd812e..f1420141e07a 100644 --- a/Gemfile +++ b/Gemfile @@ -1,2 +1,4 @@ source "https://rubygems.org" -gemspec +gemspecs +gem "webrick", "~> 1.7" +gem "minimal-mistakes-jekyll" \ No newline at end of file diff --git a/README.md b/README.md index cb367d078a6b..bfe1352c0743 100644 --- a/README.md +++ b/README.md @@ -1,8 +1,15 @@ +my github blog used mmistakes. + +--- # [Minimal Mistakes Jekyll theme](https://mmistakes.github.io/minimal-mistakes/) [![LICENSE](https://img.shields.io/badge/license-MIT-lightgrey.svg)](https://raw.githubusercontent.com/mmistakes/minimal-mistakes/master/LICENSE) [![Jekyll](https://img.shields.io/badge/jekyll-%3E%3D%203.7-blue.svg)](https://jekyllrb.com/) + +
+ Introduction + Minimal Mistakes is a flexible two-column Jekyll theme, perfect for building personal sites, blogs, and portfolios. As the name implies, styling is purposely minimalistic to be enhanced and customized by you :smile:. :sparkles: See what's new in the [CHANGELOG](CHANGELOG.md). @@ -68,6 +75,11 @@ Additional sample posts are available under [posts archive][year-archive] on the [tags-archive]: https://mmistakes.github.io/minimal-mistakes/tags/ [year-archive]: https://mmistakes.github.io/minimal-mistakes/year-archive/ +
+ +
+ Dev + ## Installation There are three ways to install: as a [gem-based theme](https://jekyllrb.com/docs/themes/#understanding-gem-based-themes), as a [remote theme](https://blog.github.com/2017-11-29-use-any-theme-with-github-pages/) (GitHub Pages compatible), or forking/directly copying all of the theme files into your project. @@ -175,7 +187,11 @@ To set up your environment to develop this theme, run `bundle install`. To test the theme, run `bundle exec rake preview` and open your browser at `http://localhost:4000/test/`. This starts a Jekyll server using content in the `test/` directory. As modifications are made to the theme and test site, it will regenerate and you should see the changes in the browser after a refresh. -## Credits +
+ +
+ + Credits ### Creator @@ -287,3 +303,5 @@ Lunr is distributed under the terms of the [MIT License](http://opensource.org/l Minimal Mistakes incorporates [clipboard.js](https://clipboardjs.com/), Copyright (c) 2021 Zeno Rocha. Clipboard.js is distributed under the terms of the [MIT License](https://opensource.org/licenses/MIT). + +
\ No newline at end of file diff --git a/_config.yml b/_config.yml index 479b9ee27945..8549779c61cd 100644 --- a/_config.yml +++ b/_config.yml @@ -12,28 +12,28 @@ # theme : "minimal-mistakes-jekyll" # remote_theme : "mmistakes/minimal-mistakes" -minimal_mistakes_skin : "default" # "air", "aqua", "contrast", "dark", "dirt", "neon", "mint", "plum", "sunrise" +minimal_mistakes_skin : "contrast" #"default" # "air", "aqua", "contrast", "dark", "dirt", "neon", "mint", "plum", "sunrise" # Site Settings -locale : "en-US" -title : "Site Title" -title_separator : "-" -subtitle : # site tagline that appears below site title in masthead -name : "Your Name" -description : "An amazing website." -url : # the base hostname & protocol for your site e.g. "https://mmistakes.github.io" +locale : "ko-KR" +title : "100xoo Land" +title_separator : "|" +subtitle : "개발새발 블로깅" # site tagline that appears below site title in masthead +name : "100xoo" +description : "Abracadabra Alakazam" +url : "https://100xoo.github.io" baseurl : # the subpath of your site, e.g. "/blog" -repository : # GitHub username/repo-name e.g. "mmistakes/minimal-mistakes" +repository : "100xoo/ghblog-comments" # GitHub username/repo-name e.g. "mmistakes/minimal-mistakes" teaser : # path of fallback teaser image, e.g. "/assets/images/500x300.png" -logo : # path of logo image to display in the masthead, e.g. "/assets/images/88x88.png" +logo : "/assets/images/nyanCat_logo.png" # path of logo image to display in the masthead, e.g. "/assets/images/88x88.png" masthead_title : # overrides the website title displayed in the masthead, use " " for no title -# breadcrumbs : false # true, false (default) +breadcrumbs : true # true, false (default), 네비게이션 words_per_minute : 200 enable_copy_code_button : # true, false (default) copyright : # "copyright" name, defaults to site.title copyright_url : # "copyright" URL, defaults to site.url comments: - provider : # false (default), "disqus", "discourse", "facebook", "staticman", "staticman_v2", "utterances", "giscus", "custom" + provider : "giscus" # false (default), "disqus", "discourse", "facebook", "staticman", "staticman_v2", "utterances", "giscus", "custom" disqus: shortname : # https://help.disqus.com/customer/portal/articles/466208-what-s-a-shortname- discourse: @@ -47,17 +47,18 @@ comments: theme : # "github-light" (default), "github-dark" issue_term : # "pathname" (default) giscus: - repo_id : # Shown during giscus setup at https://giscus.app - category_name : # Full text name of the category - category_id : # Shown during giscus setup at https://giscus.app - discussion_term : # "pathname" (default), "url", "title", "og:title" - reactions_enabled : # '1' for enabled (default), '0' for disabled - theme : # "light" (default), "dark", "dark_dimmed", "transparent_dark", "preferred_color_scheme" - strict : # 1 for enabled, 0 for disabled (default) - input_position : # "top", "bottom" # The comment input box will be placed above or below the comments - emit_metadata : # 1 for enabled, 0 for disabled (default) # https://github.com/giscus/giscus/blob/main/ADVANCED-USAGE.md#imetadatamessage - lang : # "en" (default) - lazy : # true, false # Loading of the comments will be deferred until the user scrolls near the comments container. + # repo : "100xoo/ghblog-comments" + repo_id : "R_kgDOMH0UjQ" # Shown during giscus setup at https://giscus.app + category_name : "Comments" # Full text name of the category + category_id : "DIC_kwDOMH0Ujc4CgATH" # Shown during giscus setup at https://giscus.app + discussion_term : "pathname" # "pathname" (default), "url", "title", "og:title" + reactions_enabled : "1" # '1' for enabled (default), '0' for disabled + theme : "preferred_color_scheme" # "light" (default), "dark", "dark_dimmed", "transparent_dark", "preferred_color_scheme" + strict : 0 # 1 for enabled, 0 for disabled (default) + input_position : "bottom" # "top", "bottom" # The comment input box will be placed above or below the comments + emit_metadata : 0 # 1 for enabled, 0 for disabled (default) # https://github.com/giscus/giscus/blob/main/ADVANCED-USAGE.md#imetadatamessage + lang : "ko" # "en" (default) + lazy : false # true, false # Loading of the comments will be deferred until the user scrolls near the comments container. staticman: branch : # "master" endpoint : # "https://{your Staticman v3 API}/v3/entry/github/" @@ -83,7 +84,7 @@ google: # SEO Related google_site_verification : bing_site_verification : -naver_site_verification : +naver_site_verification : "d92ee934bcce2b62163d6a05231b393a51d5b8de" yandex_site_verification : baidu_site_verification : @@ -104,51 +105,39 @@ social: # Analytics analytics: - provider : false # false (default), "google", "google-universal", "google-gtag", "custom" + provider : "google-gtag" # false # false (default), "google", "google-universal", "google-gtag", "custom" google: - tracking_id : - anonymize_ip : # true, false (default) + tracking_id : "G-4SCR27TTZ5" + anonymize_ip : false # true, false (default) # Site Author author: - name : "Your Name" + name : "Jongmin" avatar : # path of avatar image, e.g. "/assets/images/bio-photo.jpg" - bio : "I am an **amazing** person." - location : "Somewhere" + bio : "Curiouser and curiouser" + location : "Seoul, South Korea" email : links: - label: "Email" icon: "fas fa-fw fa-envelope-square" - # url: "mailto:your.name@email.com" + url: "mailto:98.prmj@gmail.com" - label: "Website" icon: "fas fa-fw fa-link" - # url: "https://your-website.com" - - label: "Twitter" - icon: "fab fa-fw fa-twitter-square" - # url: "https://twitter.com/" - - label: "Facebook" - icon: "fab fa-fw fa-facebook-square" - # url: "https://facebook.com/" + url: "https://100xoo.github.io" - label: "GitHub" - icon: "fab fa-fw fa-github" - # url: "https://github.com/" - - label: "Instagram" - icon: "fab fa-fw fa-instagram" - # url: "https://instagram.com/" + icon: "fab fa-fw fa-square-github" + url: "https://github.com/100xoo" + - label: "Linkedin" + icon: "fab fa-fw fa-linkedin" + url: "https://www.linkedin.com/in/jongminleee/" # Site Footer footer: links: - - label: "Twitter" - icon: "fab fa-fw fa-twitter-square" - # url: - - label: "Facebook" - icon: "fab fa-fw fa-facebook-square" - # url: - label: "GitHub" icon: "fab fa-fw fa-github" - # url: + url: https://github.com/100xoo - label: "GitLab" icon: "fab fa-fw fa-gitlab" # url: @@ -226,11 +215,11 @@ sass: # Outputting permalink: /:categories/:title/ -timezone: # https://en.wikipedia.org/wiki/List_of_tz_database_time_zones +timezone: Asia/Seoul # Pagination with jekyll-paginate -paginate: 5 # amount of posts to show +paginate: 10 # amount of posts to show paginate_path: /page:num/ # Pagination with jekyll-paginate-v2 @@ -289,16 +278,16 @@ tag_archive: type: liquid path: /tags/ # https://github.com/jekyll/jekyll-archives -# jekyll-archives: -# enabled: -# - categories -# - tags -# layouts: -# category: archive-taxonomy -# tag: archive-taxonomy -# permalinks: -# category: /categories/:name/ -# tag: /tags/:name/ +jekyll-archives: + enabled: + - categories + - tags + layouts: + category: archive-taxonomy + tag: archive-taxonomy + permalinks: + category: /categories/:name/ + tag: /tags/:name/ # HTML Compression @@ -319,6 +308,9 @@ defaults: layout: single author_profile: true read_time: true - comments: # true + comments: true share: true related: true + show_date: true + +#date_format: "%Y-%m-%d" \ No newline at end of file diff --git a/_data/navigation.yml b/_data/navigation.yml index 6f30866f3bed..971f5efa9881 100644 --- a/_data/navigation.yml +++ b/_data/navigation.yml @@ -1,7 +1,21 @@ # main links main: - - title: "Quick-Start Guide" - url: https://mmistakes.github.io/minimal-mistakes/docs/quick-start-guide/ + # - title: "Quick-Start Guide" + # url: https://mmistakes.github.io/minimal-mistakes/docs/quick-start-guide/ + - title: "Category" + url: /categories/ + - title: "Tag" + url: /tags/ + - title: "Search" + url: /search/ + +docs: + - title: "Shortcuts" + children: + - title: "Category" + url: /categories/ + - title: "Tag" + url: /tags/ # - title: "About" # url: https://mmistakes.github.io/minimal-mistakes/about/ # - title: "Sample Posts" diff --git a/_pages/404.md b/_pages/404.md new file mode 100644 index 000000000000..61cf4c07f201 --- /dev/null +++ b/_pages/404.md @@ -0,0 +1,22 @@ +--- +title: "Page Not Found" +excerpt: "Page not found. Your pixels are in another canvas." +sitemap: false +permalink: /404.html +--- + +![](/assets/images/404pageNotFound.png){: style="display:block; margin-left: auto; margin-right: auto;"} + + + + \ No newline at end of file diff --git a/_pages/category-archive.md b/_pages/category-archive.md new file mode 100644 index 000000000000..3cd6f6e06761 --- /dev/null +++ b/_pages/category-archive.md @@ -0,0 +1,7 @@ +--- +title: "Category" +layout: categories +permalink: /categories/ +author_profile: true +sidebar_main: true +--- \ No newline at end of file diff --git a/_pages/search.md b/_pages/search.md new file mode 100644 index 000000000000..402ef3caf1fa --- /dev/null +++ b/_pages/search.md @@ -0,0 +1,5 @@ +--- +title: "Search" +layout: search +permalink: /search/ +--- diff --git a/_pages/tag-archive.md b/_pages/tag-archive.md new file mode 100644 index 000000000000..58ae8e76afc6 --- /dev/null +++ b/_pages/tag-archive.md @@ -0,0 +1,7 @@ +--- +title: "Tag" +layout: tags +permalink: /tags/ +author_profile: true +sidebar_main: true +--- \ No newline at end of file diff --git a/_posts/2023/2023-12-11-DevOps-Definition.md b/_posts/2023/2023-12-11-DevOps-Definition.md new file mode 100644 index 000000000000..95d92994f08e --- /dev/null +++ b/_posts/2023/2023-12-11-DevOps-Definition.md @@ -0,0 +1,116 @@ +--- +layout: single +title: "데브옵스 정의" +categories: DevOps +tag: [DevOps] +toc: true +--- + +## DevOps 정의 + +### DevOps 모델 + +애플리케이션과 서비스를 빠른 속도로 제공할 수 있도록 조직의 역량을 향상시키는 문화 철학, 방식 및 도구의 조합 + +기존의 소프트웨어 개발 및 인프라 관리 프로세스를 사용하는 조직보다 제품을 더 빠르게 혁신하고 개선 + +빠른 속도를 통해 조직은 고객을 더 잘 지원하고 시장에서 좀 더 효과적으로 경쟁 + +![DevOps](/images/2023/12/Devops.png) + +### 작동 방식 + +- 개발팀과 운영팀이 더 이상 "사일로"에 묶여 있지 않음 +- 때로는 이 두 팀이 단일팀으로 병합되어 엔지니어가 개발에서 테스트, 배포, 운영에 이르기까지 전체 애플리케이션 수명 주기에 걸쳐 작업하고 단일 기능에 한정되지 않은 광범위한 기술을 개발 + +- 일부 DevOps 모델에서 품질 보증팀과 보안팀 또한 애플리케이션 수명 주기에 걸쳐 개발 및 운영과 좀 더 긴밀하게 통합 +- DevOps 팀 전체가 보안을 중점으로 두는 경우 때때로 DevSecOps라고 불림 + +- DevOps 방식을 사용하여 속도가 느리고 수동으로 수행되던 프로세스를 자동화 +- 애플리케이션을 안정적으로 빠르게 운영하고 개선하는 데 도움이 되는 기술 스택과 도구를 사용 + +→ 다른 팀의 도움이 필요했을 코드 배포 또는 인프라 프로비저닝과 같이 작업을 독립적으로 수행할 수 있으며, 따라서 팀의 작업 속도가 더욱 빨라짐 + +### DevOps의 이점 + +- **속도** + - 작업 속도가 빨라지므로 고객을 위해 더 빠르게 혁신하고, 시장 변화에 더 잘 적응하고, 좀 더 효율적으로 비즈니스 성과를 창출할 수 있음 + - ex) 마이크로 서비스와 지속적 전달을 사용하면 팀에서 서비스를 주도적으로 운영하여 + 업데이트를 좀 더 빠르게 릴리스 가능 +- **신속한 제공** + - 릴리스의 빈도와 속도를 개선하여 제품을 더 빠르게 혁신하고 개선 + - 새로운 기능의 릴리스와 버그 수정 속도가 빨라질수록 고객의 요구에 더 빠르게 대응하여 + 경쟁 우위를 강화 + - 지속적 통합과 지속적 전달은 빌드에서 배포까지 소프트웨어 릴리스 프로세스를 자동화하는 방식 +- **안정성** + - 더욱 빠르게 안정적으로 제공할 수 있도록 애플리케이션 업데이트와 인프라 변경의 품질을 보장 + - 지속적 통합 및 지속적 전달과 같은 방식을 사용하여 각 변경 사항이 제대로 작동하며 + 안전한지 테스트 + - 모니터링과 로깅 방식을 통해 실시간으로 성능에 대한 정보를 얻음 +- **확장** + - 규모에 따라 인프라와 개발 프로세스를 운영 및 관리 + - 자동화와 일관성이 지원되므로 위험을 줄이면서 복잡한 시스템 또는 변화하는 시스템을 효율적으로 관리(휴먼 에러 방지) + - ex) 코드형 인프라를 사용하면 개발, 테스트 및 프로덕션 환경을 반복 가능하고 좀 더 효율적인 방식으로 관리 +- **협업 강화** + - 주인의식 및 책임과 같은 가치를 강조하는 DevOps 문화 모델에서 좀 더 효과적인 팀을 구축 + - 개발자와 운영팀은 긴밀하게 협력하고, 많은 책임을 공유하며, 워크플로를 결합 + → 비효율성을 줄이고 시간을 절약 + ex) 개발자와 운영팀 간의 인도 기간 단축, 실행되는 환경을 고려한 코드 작성 등 +- **보안** + - 제어를 유지하고 규정을 준수하면서 신속하게 진행 + - 자동화된 규정 준수 정책, 세분화된 제어 및 구성 관리 기술을 사용함으로써 보안을 그대로 유지하면서 DevOps 모델을 도입할 수 있음 + - ex) 코드형 인프라와 코드형 정책을 사용하면 규모에 따라 규정 준수를 정의하고 추적 가능 + + +### DevOps가 중요한 이유 + +20세기에 실제 상품을 제조하는 기업이 산업 자동화를 통해 제품의 설계, 생산 및 전달 방법을 혁신한 것과 마찬가지로, 오늘날의 기업은 소프트웨어를 구축하고 제공하는 방법을 혁신해야 함 + +## DevOps 모델을 도입하는 방법 + +**DevOps 문화 철학** + +- DevOps는 기존에 사일로에 묶여 있던 개발과 운영이라는 두 팀 간의 장벽을 없애줌 +일부 조직에서는 개발팀과 운영팀이 나뉘어 있지 않고 엔지니어가 두 업무를 모두 수행할 수도 +- DevOps에서는 두 팀이 함께 작업하여 개발자의 생산성과 운영의 안정성을 모두 최적화 +- DevOps 모델을 사용하는 조직은 어떻게 구성되어 있든, 전체 개발 및 인프라 수명 주기를 스스로의 책임으로 간주하는 팀들로 구성 + +**DevOps 방식 설명** + +개발과 인프라 관리 프로세스의 자동화 및 간소화를 통해 더 빠르게 혁신할 수 있도록 → 적절한 도구 + +- 기본 방식 중 하나는 *소규모 업데이트*를 자주 수행하는 것 + - 기존 릴리스 방식에서 수행되는 낮은 빈도의 업데이트보다 일반적으로 좀 더 증분적인 특성 + - 소규모로 자주 업데이트하면 각 배포의 위험이 줄어듬 + - 팀에서 오류의 원인이 되는 최근 배포를 확인할 수 있으므로 더 빠르게 버그를 해결 가능 + - 기존 소프트웨어 개발 방식을 사용하는 조직보다 훨씬 더 자주 업데이트를 배포 +- *마이크로 서비스 아키텍처*를 사용하여 애플리케이션의 유연성과 혁신의 속도를 높일 수 있음 + + +### 기업에서의 정의 + +Red Hat : 신속한 고품질 서비스 제공을 통해 비즈니스 가치를 높이고 대응 능력을 개선할 목적으로 기업 문화, 자동화, 플랫폼 설계에 접근하는 방식 +AWS : 애플리케이션과 서비스를 빠른 속도로 제공할 수 있도록 조직의 역량을 향상시키는 문화 철학, 방식 및 도구의 조합 + +기존의 소프트웨어 개발 및 인프라 관리 프로세스를 사용하는 조직보다 제품을 더 빠르게 혁신하고 개선 +-> 조직은 고객을 더 잘 지원하고 시장에서 좀 더 효과적으로 경쟁 + +기존의 배포 방식에선 개발부터 디버깅, 컴파일 등 운영까지의 과정에서 불필요한 소요가 많았다. +또한 개발팀과 운영팀이 지향하는 바가 서로 달랐다. +개발팀 : 새로운 기술을 도입하고 새로운 서비스를 제공하고 싶다. +운영팀 : 현재 운영중인 서비스가 안정적으로 동작했으면 좋겠다. +-> 개발팀과 운영팀 사이에 사일로(부서 이기주의) 발생 + +이러한 상황에서 개발과 운영 모두 잘 이해한 상태의 팀(DevOps 팀)이 있다면 어떨까 +* 속도가 느리고 수동으로 수행되던 프로세스를 자동화 +* 애플리케이션을 안정적으로 빠르게 운영하고 개선하는 데 도움이 되는 기술 스택과 도구를 사용 +* 위의 기술과 도구를 이용해 코드 배포 또는 인프라 프로비저닝과 같은 작업을 독립적으로 수행 + + +세상은 빠르게 변화하고 있고 고객은 이러한 변화의 니즈를 충족시켜 주길 원한다. +기업은 이 니즈를 충족시키기 위해 고객의 피드백이나 새로운 서비스를 더 빠르게 개발하고 배포해야 하며 이러한 프로세스에 데브옵스가 안성맞춤인 것 같다. + + +## ***Reference*** +https://aws.amazon.com/ko/devops/what-is-devops/
+[Stephen Orban - 엔터프라이즈 기업의 클라우드 도입 모범 사례](https://aws.amazon.com/ko/blogs/korea/stepen-orban-an-e-book-of-cloud-best-practices-for-your-enterprise/) \ No newline at end of file diff --git a/_posts/2023/2023-12-11-DevOps-Process.md b/_posts/2023/2023-12-11-DevOps-Process.md new file mode 100644 index 000000000000..b6c2fc5a5e96 --- /dev/null +++ b/_posts/2023/2023-12-11-DevOps-Process.md @@ -0,0 +1,48 @@ +--- +layout: single +title: "데브옵스 프로세스" +categories: DevOps +tag: [DevOps,Process] +--- + +DevOps가 보다보면 참 좋은 것 같은데 실질적으로 도입하기엔 몇 가지 고려사항이 있는 것 같다. +콘웨이의 법칙이라는 재밌는 이야기가 있는데, 1967년에 앨빈 콘웨이 박사가 +조직이 만드는 시스템의 설계는 조직의 의사소통 구조를 닮는다 라는 말을 했었다. + +1. DevOps라는 조직은 책임과 권한이 필요하다. +빠르게 테스트하고 배포해야하는 만큼 이에 대한 권한이 주어져야하고 또 책임도 필요하게 된다. +이러한 이유로 조직 문화(기업 문화)가 수평적 관계를 지향하는 게 유리할 것 같다. +2. DevOps 문화를 더욱 잘 활용하기 위해선 이에 맞는 아키텍처가 필요하다. +기존의 모놀리식 환경에서도 이를 활용할 수 있겠지만 가장 효율적으로 이용하기 위해서는 +MSA 아키텍처를 도입하는게 좋다. 단편적으로 MSA 아키텍처의 세분화 된 서비스를 통해 결합도가 낮아지고 각 서비스간의 영향도를 낮추면 더 빠르게 개발과 배포가 가능해질 것이다. +3. MSA와 DevOps를 도입했다면 이번엔 너무 많은 서비스와 릴리스 빈도 증가로 관리 운영이 힘들어 질 수 있다. + +DevOps를 위해 필요한 것들 +AWS의 DevOps 방식(모범 사례) +* CI +* CD +* MSA +* IaC +* Monitoring, Logging +* Communication + + + +DevOps lifecycle +1. Plan +2. Code +3. Build +4. Test +5. Package +6. Release +7. Deploy +8. Operate +9. Monitor +10. Repeat! + +![참고 이미지](https://velog.velcdn.com/images/dalonn98/post/e84e75a9-5308-423f-b354-b0fff0035fe0/image.png) + +https://www.redhat.com/ko/topics/devops +https://aws.amazon.com/ko/devops/what-is-devops/ +https://shalb.com/wp-content/uploads/2019/11/Devops1-2048x1338.jpeg +https://octopus.com/devops/ \ No newline at end of file diff --git a/_posts/2024/02/2024-02-06-Secuguard SSE Agent Reinstall.md b/_posts/2024/02/2024-02-06-Secuguard SSE Agent Reinstall.md new file mode 100644 index 000000000000..b125c7ec6e0d --- /dev/null +++ b/_posts/2024/02/2024-02-06-Secuguard SSE Agent Reinstall.md @@ -0,0 +1,25 @@ +--- +layout: single +title: Secuguard SSE Agent 재설치 +categories: Other Tips +tags: + - Tips + - TroubleShooting + - Linux + - ThirdParty +--- +취약점 점검 솔루션 Secuguard 관련 내용입니다. + +netstat -tnlp 30041 + +\-> process name은 ssed 인 것 같다. + +``` +pkill -9 -ef PROCESS_NAME +``` + +rm -rf /opt/SSExplorer + +**rm -rf /usr/lib/systemd/system/ssed.service** + +얘 때문에 재설치 시 오류가 발생하는 것 같다. diff --git a/_posts/2024/02/2024-02-14-tomcat catalinaout too large.md b/_posts/2024/02/2024-02-14-tomcat catalinaout too large.md new file mode 100644 index 000000000000..095c403e6b9b --- /dev/null +++ b/_posts/2024/02/2024-02-14-tomcat catalinaout too large.md @@ -0,0 +1,61 @@ +--- +layout: single +title: Tomcat Catalina.out 파일 용량 증가 문제 해결 +categories: TroubleShooting +tags: [Linux, Tomcat, Catalina.out, Middle-ware] +toc: true +--- + +## 실행 명령 +1. 로그 생성 위치 확인(catalina.out 있는 곳) + +2. logrotate 폴더에 tomcat 파일 생성 +```bash +# sudo vi /etc/logratate.d/tomcat +$TOMCAT_HOME/logs/catalina.out { + copytruncate + daily + size 10M + rotate 30 + compress + missingok + notifempty + dateext +} +``` +3. logrotate에서 tomcat 파일 생성 후 logrotate 데몬 실행 +```bash +logrotate -f /etc/logrotate.d/tomcat +``` +logrotate 실행 시 옵션
+-d : debug
+-v : verbose, 실행 과정 확인
+ +### 설정 시 옵션 +copytruncate -> logrotate의 디폴트값은 rename이다.
이에 따라 기존 파일의 이름만 바꾸게 되어 내용이 그대로라고 한다. + +로테이트 후 이름만 바뀌어 로그 파일이 계속 쌓이게 됨
=> copytruncate를 사용하면 임시 파일 생성 후 룰에 따라 이름 변경, 기존 파일 내용 복사 후 비워줌 + +* 간단하면서 편리한 기능이지만 크기가 GB 단위처럼 클 경우 시스템 I/O 로드에 영향을 끼칠 수 있으니 주의 +* 가장 이상적인 해결 방법인 signal을 사용하는게 좋다고 한다 [(참고 블로그)](https://brunch.co.kr/@alden/27) + + +로테이트 실행 주기 : yearly, monthly, weekly, daily + +rotate [number] : 로그파일 개수 초과 시 가장 오래된 파일 삭제 + +create [권한] [유저] [그룹] : 로테이트 시 생성되는 로그파일 권한 및 소유자 지정 + +notifempty/ifempty : 로그 내용이 없으면 로테이트 실행 X/로그 내용이 없어도 로테이트 실행 O + +compress/nocompress : 로테이트로 생성되는 로그파일 gzip으로 압축하여 생성/ 생성되는 로그파일 압축 X + +missingok : 로그파일 발견하지 못해도 에러처리 X + +dateext : 로테이트 파일 이름에 날짜가 들어가도록 생성 + +size [number K,M,G] : 로그 파일 크기가 설정보다 커지면 로테이트 실행 + +maxage [number] : 파일이 지정된 숫자(일) 지나면 삭제 + +postrotate/endscript : 실행 후 스크립트 파일 실행/postrotate(스크립트 실행 옵션) 이후 들어가는 옵션 diff --git a/_posts/2024/03/2024-03-14-Python version Control-pyenv.md b/_posts/2024/03/2024-03-14-Python version Control-pyenv.md new file mode 100644 index 000000000000..86a92c57371c --- /dev/null +++ b/_posts/2024/03/2024-03-14-Python version Control-pyenv.md @@ -0,0 +1,36 @@ +--- +layout: single +title: Python 버전 관리 - pyenv +categories: Other Tips +tags: + - Tips + - Linux + - Python +--- + +파이썬을 종종 사용하는 경우가 생기는데, 필요한 파이썬 버전이 다를때가 많다. + +이러한 경우 pyenv를 이용하여 원하는 버전을 설치하고 관리할 수 있다. + +ex) A : python 3.7 사용/ B : python 3.11 사용 + +[https://github.com/pyenv/pyenv](https://github.com/pyenv/pyenv) + +```bash +pyenv update + +# 설치 가능한 파이썬 버전 리스트 +pyenv install --list + +# 원하는 버전 설치 +pyenv install {python version} + +# 설치한 파이썬 리스트 +pyenv versions + +# 선택한 위치에서만 해당 버전 사용 +pyenv local {python version} + +# 전체 위치에서 해당 버전 사용 +pynev global {python version} +``` diff --git a/_posts/2024/04/2024-04-16-HyperV Expanding capacity.md b/_posts/2024/04/2024-04-16-HyperV Expanding capacity.md new file mode 100644 index 000000000000..7c677e815983 --- /dev/null +++ b/_posts/2024/04/2024-04-16-HyperV Expanding capacity.md @@ -0,0 +1,54 @@ +--- +layout: single +title: Hyper-V에서 용량 확장하기 +categories: Hypervisor +tags: + - Tips + - Hyper-V + - Linux +--- + + +## Hyper-V 설정(서버가 종료돼있는 상태에서 작업 진행) + +1. Hyper-V 관리자 디스크 편집 +![](/images/2024/04/2024-04-16-Hyper-V_1.png) + +2. 변경하려는 VM의 디스크파일 vhd나 vhdx 파일 선택 +![](/images/2024/04/2024-04-16-Hyper-V_2.png) + +3. 확장 선택(다른 기능은 아직 안써봤다) +![](/images/2024/04/2024-04-16-Hyper-V_3.png) + +4. 변환하려는 크기 지정 후 마침(원래 크기 50GB) +![](/images/2024/04/2024-04-16-Hyper-V_4.png) + +5. 마지막으로 서버를 다시 켜고 설정을 하면 된다. +![](/images/2024/04/2024-04-16-Hyper-V_5.png) + + +## Linux 내부 설정 + +1. df -hT 를 사용하여 현재 사용가능한 디스크 용량 및 타입을 확인 +![](/images/2024/04/2024-04-16-Hyper-V_6.png) + +2. lsblk(or fdisk -l)을 입력하여 현재 스토리지(블록) 상태 확인 +![](/images/2024/04/2024-04-16-Hyper-V_7.png)
+현재 10GB 추가 할당하여 총 디스크 용량 60GB로 변경하였고 기존 50GB인 상태였기 때문에 용량 확장만 하면 된다. +10GB 용량의 파티션을 따로 생성하는 방법도 있겠지만 여기선 기존 루트(/)의 용량 확장을 진행하려고 한다. + +3. parted 사용하여 파티션 확장 +parted 명령 실행 후 print free +sda 3의 용량이 나오고 여분 공간 10GB가 보인다. +![](/images/2024/04/2024-04-16-Hyper-V_8.png)
+resizepart 를 입력한 후 변경할 번호(3번) 입력, yes, -1은 마지막이라는 뜻 +![](/images/2024/04/2024-04-16-Hyper-V_9.png) + +4. 파티션은 늘렸지만 파일시스템을 동일하게 만들어줘야 실제 사용이 가능하다.
+resize2fs를 이용하여 작업한다.
+ext4를 사용하고 있기 때문에 resize2fs를 썼는데 xfs의 경우는 xfs_grow 를 사용하면 될 것 같다. +![](/images/2024/04/2024-04-16-Hyper-V_10.png) + + + +완료 diff --git a/_posts/2024/05/2024-05-31-Firstpost_HelloWorld.md b/_posts/2024/05/2024-05-31-Firstpost_HelloWorld.md new file mode 100644 index 000000000000..267f8b28afbd --- /dev/null +++ b/_posts/2024/05/2024-05-31-Firstpost_HelloWorld.md @@ -0,0 +1,8 @@ +--- +layout: single +title: "first post 🥳" +--- + +## Hello World + +Nice to meet you diff --git a/_posts/2024/05/2024-05-31-Practice_CIFAR-10.md b/_posts/2024/05/2024-05-31-Practice_CIFAR-10.md new file mode 100644 index 000000000000..2cde93a1dcd9 --- /dev/null +++ b/_posts/2024/05/2024-05-31-Practice_CIFAR-10.md @@ -0,0 +1,656 @@ +--- +layout: single +title: "Practice CIFAR-10" +categories: AI +tag: Paper Review +toc: true +author_profile: true +sidebar: + nav: "docs" +--- + + + +## CIFAR-10 데이터셋 불러오기 + + +```python +import os +import random +import numpy as np +import matplotlib.pyplot as plt + +import tensorflow as tf +from tensorflow.keras import Sequential +from tensorflow.keras.layers import Dense, Conv2D, MaxPooling2D, Dropout, Flatten + +from tensorflow.keras.datasets import cifar10 +from tensorflow.keras.utils import to_categorical +from matplotlib.ticker import (MultipleLocator, FormatStrFormatter) +from dataclasses import dataclass +``` + + +```python +SEED_VALUE = 42 + +# 임의의 랜덤 시드 사용(42) +random.seed(SEED_VALUE) +np.random.seed(SEED_VALUE) +tf.random.set_seed(SEED_VALUE) +``` + + +```python +# load_data() 함수를 사용하여 데이터셋을 로드하고 샘플 수와 데이터의 형태를 확인 + (X_train, y_train), (X_test, y_test) = cifar10.load_data() + +print(X_train.shape) +print(X_test.shape) +``` + + Downloading data from https://www.cs.toronto.edu/~kriz/cifar-10-python.tar.gz + 170498071/170498071 [==============================] - 13s 0us/step + (50000, 32, 32, 3) + (10000, 32, 32, 3) + + +# 데이터셋의 샘플 이미지 표시 + + +```python +plt.figure(figsize=(7, 7)) + +num_rows = 10 +num_cols = 10 + +for i in range(num_rows*num_cols): + ax = plt.subplot(num_rows, num_cols, i + 1) + plt.imshow(X_train[i,:,:]) + plt.axis("off") +``` + + + +![png](/images/2024/05/2024-05-31-02-output_5_0.png) + + +## 데이터셋 전처리 + + +```python +# 이미지를 [0, 1] 범위로 정규화 +X_train = X_train.astype("float32") / 255 +X_test = X_test.astype("float32") / 255 + +# 레이블을 정수에서 범주형 데이터로 변경 +print('training sample: ', y_train[0]) + +# 레이블을 원-핫 인코딩으로 변환 +y_train = to_categorical(y_train) +y_test = to_categorical(y_test) + +print('categorical one-hot encoded labels: ', y_train[0]) +``` + + Original (integer) label for the first training sample: [6] + After conversion to categorical one-hot encoded labels: [0. 0. 0. 0. 0. 0. 1. 0. 0. 0.] + + +## 데이터 세트 및 학습 구성 매개 변수 + + +```python +@dataclass(frozen=True) +class DatasetConfig: + NUM_CLASSES: int = 10 + IMG_HEIGHT: int = 32 + IMG_WIDTH: int = 32 + NUM_CHANNELS: int = 3 + +@dataclass(frozen=True) +class TrainingConfig: + EPOCHS: int = 31 + BATCH_SIZE: int = 256 + LEARNING_RATE: float = 0.001 +``` + +## Keras의 CNN 모델 구현 + + +```python +# Keras에서 사전 정의된 계층을 사용하여 네트워크 모델을 구축/정의 +def cnn_model(input_shape=(32, 32, 3)): + + model = Sequential() + + #------------------------------------ + # Conv Block 1: 32 Filters, MaxPool. + #------------------------------------ + model.add(Conv2D(filters=32, kernel_size=3, padding='same', activation='relu', input_shape=input_shape)) + model.add(Conv2D(filters=32, kernel_size=3, padding='same', activation='relu')) + model.add(MaxPooling2D(pool_size=(2, 2))) + + #------------------------------------ + # Conv Block 2: 64 Filters, MaxPool. + #------------------------------------ + model.add(Conv2D(filters=64, kernel_size=3, padding='same', activation='relu')) + model.add(Conv2D(filters=64, kernel_size=3, padding='same', activation='relu')) + model.add(MaxPooling2D(pool_size=(2, 2))) + + #------------------------------------ + # Conv Block 3: 64 Filters, MaxPool. + #------------------------------------ + model.add(Conv2D(filters=64, kernel_size=3, padding='same', activation='relu')) + model.add(Conv2D(filters=64, kernel_size=3, padding='same', activation='relu')) + model.add(MaxPooling2D(pool_size=(2, 2))) + + #------------------------------------ + # Flatten the convolutional features. + #------------------------------------ + model.add(Flatten()) + model.add(Dense(512, activation='relu')) + model.add(Dense(10, activation='softmax')) + + return model +``` + + +```python +# 모델 생성 +model = cnn_model() +model.summary() +``` + + Model: "sequential" + _________________________________________________________________ + Layer (type) Output Shape Param # + ================================================================= + conv2d (Conv2D) (None, 32, 32, 32) 896 + + conv2d_1 (Conv2D) (None, 32, 32, 32) 9248 + + max_pooling2d (MaxPooling2 (None, 16, 16, 32) 0 + D) + + conv2d_2 (Conv2D) (None, 16, 16, 64) 18496 + + conv2d_3 (Conv2D) (None, 16, 16, 64) 36928 + + max_pooling2d_1 (MaxPoolin (None, 8, 8, 64) 0 + g2D) + + conv2d_4 (Conv2D) (None, 8, 8, 64) 36928 + + conv2d_5 (Conv2D) (None, 8, 8, 64) 36928 + + max_pooling2d_2 (MaxPoolin (None, 4, 4, 64) 0 + g2D) + + flatten (Flatten) (None, 1024) 0 + + dense (Dense) (None, 512) 524800 + + dense_1 (Dense) (None, 10) 5130 + + ================================================================= + Total params: 669354 (2.55 MB) + Trainable params: 669354 (2.55 MB) + Non-trainable params: 0 (0.00 Byte) + _________________________________________________________________ + + + +```python +# 모델 컴파일 +model.compile(optimizer='rmsprop', + loss='categorical_crossentropy', + metrics=['accuracy'], + ) +``` + + +```python +# 모델 학습 +history = model.fit(X_train, + y_train, + batch_size=TrainingConfig.BATCH_SIZE, + epochs=TrainingConfig.EPOCHS, + verbose=1, + validation_split=.3, + ) +``` + + Epoch 1/31 + 137/137 [==============================] - 10s 33ms/step - loss: 2.1757 - accuracy: 0.2045 - val_loss: 1.8987 - val_accuracy: 0.3151 + Epoch 2/31 + 137/137 [==============================] - 3s 22ms/step - loss: 1.7648 - accuracy: 0.3590 - val_loss: 1.5809 - val_accuracy: 0.4207 + Epoch 3/31 + 137/137 [==============================] - 3s 24ms/step - loss: 1.5269 - accuracy: 0.4414 - val_loss: 1.4883 - val_accuracy: 0.4513 + Epoch 4/31 + 137/137 [==============================] - 3s 20ms/step - loss: 1.3787 - accuracy: 0.4998 - val_loss: 1.2668 - val_accuracy: 0.5461 + Epoch 5/31 + 137/137 [==============================] - 3s 22ms/step - loss: 1.2518 - accuracy: 0.5522 - val_loss: 1.4190 - val_accuracy: 0.5347 + Epoch 6/31 + 137/137 [==============================] - 3s 20ms/step - loss: 1.1300 - accuracy: 0.5980 - val_loss: 1.2235 - val_accuracy: 0.5575 + Epoch 7/31 + 137/137 [==============================] - 3s 23ms/step - loss: 1.0162 - accuracy: 0.6351 - val_loss: 1.0210 - val_accuracy: 0.6428 + Epoch 8/31 + 137/137 [==============================] - 3s 23ms/step - loss: 0.9169 - accuracy: 0.6729 - val_loss: 1.0173 - val_accuracy: 0.6393 + Epoch 9/31 + 137/137 [==============================] - 3s 20ms/step - loss: 0.8276 - accuracy: 0.7073 - val_loss: 0.9755 - val_accuracy: 0.6617 + Epoch 10/31 + 137/137 [==============================] - 3s 20ms/step - loss: 0.7387 - accuracy: 0.7380 - val_loss: 1.0000 - val_accuracy: 0.6583 + Epoch 11/31 + 137/137 [==============================] - 3s 23ms/step - loss: 0.6525 - accuracy: 0.7714 - val_loss: 0.8477 - val_accuracy: 0.7123 + Epoch 12/31 + 137/137 [==============================] - 3s 21ms/step - loss: 0.5736 - accuracy: 0.7949 - val_loss: 0.8547 - val_accuracy: 0.7181 + Epoch 13/31 + 137/137 [==============================] - 3s 20ms/step - loss: 0.4931 - accuracy: 0.8284 - val_loss: 0.8719 - val_accuracy: 0.7163 + Epoch 14/31 + 137/137 [==============================] - 3s 20ms/step - loss: 0.4135 - accuracy: 0.8527 - val_loss: 1.0511 - val_accuracy: 0.6809 + Epoch 15/31 + 137/137 [==============================] - 3s 20ms/step - loss: 0.3460 - accuracy: 0.8793 - val_loss: 0.9708 - val_accuracy: 0.7279 + Epoch 16/31 + 137/137 [==============================] - 3s 22ms/step - loss: 0.2758 - accuracy: 0.9017 - val_loss: 1.0801 - val_accuracy: 0.7189 + Epoch 17/31 + 137/137 [==============================] - 3s 21ms/step - loss: 0.2205 - accuracy: 0.9243 - val_loss: 1.2581 - val_accuracy: 0.7067 + Epoch 18/31 + 137/137 [==============================] - 3s 23ms/step - loss: 0.1828 - accuracy: 0.9383 - val_loss: 1.2623 - val_accuracy: 0.7232 + Epoch 19/31 + 137/137 [==============================] - 3s 20ms/step - loss: 0.1508 - accuracy: 0.9497 - val_loss: 1.3480 - val_accuracy: 0.7129 + Epoch 20/31 + 137/137 [==============================] - 3s 22ms/step - loss: 0.1192 - accuracy: 0.9602 - val_loss: 1.5366 - val_accuracy: 0.7155 + Epoch 21/31 + 137/137 [==============================] - 3s 21ms/step - loss: 0.1080 - accuracy: 0.9648 - val_loss: 1.8424 - val_accuracy: 0.6703 + Epoch 22/31 + 137/137 [==============================] - 3s 23ms/step - loss: 0.1006 - accuracy: 0.9684 - val_loss: 1.6001 - val_accuracy: 0.7140 + Epoch 23/31 + 137/137 [==============================] - 3s 21ms/step - loss: 0.0938 - accuracy: 0.9692 - val_loss: 1.7790 - val_accuracy: 0.7189 + Epoch 24/31 + 137/137 [==============================] - 3s 23ms/step - loss: 0.0870 - accuracy: 0.9727 - val_loss: 1.7076 - val_accuracy: 0.7322 + Epoch 25/31 + 137/137 [==============================] - 3s 25ms/step - loss: 0.0740 - accuracy: 0.9761 - val_loss: 1.8602 - val_accuracy: 0.7165 + Epoch 26/31 + 137/137 [==============================] - 3s 25ms/step - loss: 0.0711 - accuracy: 0.9773 - val_loss: 1.8184 - val_accuracy: 0.7195 + Epoch 27/31 + 137/137 [==============================] - 3s 23ms/step - loss: 0.0630 - accuracy: 0.9802 - val_loss: 2.0117 - val_accuracy: 0.7183 + Epoch 28/31 + 137/137 [==============================] - 3s 24ms/step - loss: 0.0676 - accuracy: 0.9795 - val_loss: 2.1262 - val_accuracy: 0.7027 + Epoch 29/31 + 137/137 [==============================] - 3s 21ms/step - loss: 0.0605 - accuracy: 0.9802 - val_loss: 2.1155 - val_accuracy: 0.7218 + Epoch 30/31 + 137/137 [==============================] - 3s 23ms/step - loss: 0.0598 - accuracy: 0.9811 - val_loss: 2.1629 - val_accuracy: 0.7207 + Epoch 31/31 + 137/137 [==============================] - 3s 23ms/step - loss: 0.0604 - accuracy: 0.9815 - val_loss: 2.1921 - val_accuracy: 0.7115 + + +## 훈련 결과 플로팅 + + +```python +def plot_results(metrics, title=None, ylabel=None, ylim=None, metric_name=None, color=None): + + fig, ax = plt.subplots(figsize=(15, 4)) + + if not (isinstance(metric_name, list) or isinstance(metric_name, tuple)): + metrics = [metrics,] + metric_name = [metric_name,] + + for idx, metric in enumerate(metrics): + ax.plot(metric, color=color[idx]) + + plt.xlabel("Epoch") + plt.ylabel(ylabel) + plt.title(title) + plt.xlim([0, TrainingConfig.EPOCHS-1]) + plt.ylim(ylim) + # Tailor x-axis tick marks + ax.xaxis.set_major_locator(MultipleLocator(5)) + ax.xaxis.set_major_formatter(FormatStrFormatter('%d')) + ax.xaxis.set_minor_locator(MultipleLocator(1)) + plt.grid(True) + plt.legend(metric_name) + plt.show() + plt.close() +``` + + +```python +# Retrieve training results. +train_loss = history.history["loss"] +train_acc = history.history["accuracy"] +valid_loss = history.history["val_loss"] +valid_acc = history.history["val_accuracy"] + +plot_results([ train_loss, valid_loss ], + ylabel="Loss", + ylim = [0.0, 5.0], + metric_name=["Training Loss", "Validation Loss"], + color=["g", "b"]); + +plot_results([ train_acc, valid_acc ], + ylabel="Accuracy", + ylim = [0.0, 1.0], + metric_name=["Training Accuracy", "Validation Accuracy"], + color=["g", "b"]) +``` + + + +![png](/images/2024/05/2024-05-31-02-output_17_0.png) + + + + + +![png](/images/2024/05/2024-05-31-02-output_17_1.png) + + + +## 모델에 드롭아웃 추가 + + +```python +def cnn_model_dropout(input_shape=(32, 32, 3)): + + model = Sequential() + + #------------------------------------ + # Conv Block 1: 32 Filters, MaxPool. + #------------------------------------ + model.add(Conv2D(filters=32, kernel_size=3, padding='same', activation='relu', input_shape=input_shape)) + model.add(Conv2D(filters=32, kernel_size=3, padding='same', activation='relu')) + model.add(MaxPooling2D(pool_size=(2, 2))) + model.add(Dropout(0.25)) + + #------------------------------------ + # Conv Block 2: 64 Filters, MaxPool. + #------------------------------------ + model.add(Conv2D(filters=64, kernel_size=3, padding='same', activation='relu')) + model.add(Conv2D(filters=64, kernel_size=3, padding='same', activation='relu')) + model.add(MaxPooling2D(pool_size=(2, 2))) + model.add(Dropout(0.25)) + + #------------------------------------ + # Conv Block 3: 64 Filters, MaxPool. + #------------------------------------ + model.add(Conv2D(filters=64, kernel_size=3, padding='same', activation='relu')) + model.add(Conv2D(filters=64, kernel_size=3, padding='same', activation='relu')) + model.add(MaxPooling2D(pool_size=(2, 2))) + model.add(Dropout(0.25)) + + #------------------------------------ + # Flatten the convolutional features. + #------------------------------------ + model.add(Flatten()) + model.add(Dense(512, activation='relu')) + model.add(Dropout(0.5)) + model.add(Dense(10, activation='softmax')) + + return model +``` + + +```python +# 모델 생성 +model_dropout = cnn_model_dropout() +model_dropout.summary() +``` + + Model: "sequential_1" + _________________________________________________________________ + Layer (type) Output Shape Param # + ================================================================= + conv2d_6 (Conv2D) (None, 32, 32, 32) 896 + + conv2d_7 (Conv2D) (None, 32, 32, 32) 9248 + + max_pooling2d_3 (MaxPoolin (None, 16, 16, 32) 0 + g2D) + + dropout (Dropout) (None, 16, 16, 32) 0 + + conv2d_8 (Conv2D) (None, 16, 16, 64) 18496 + + conv2d_9 (Conv2D) (None, 16, 16, 64) 36928 + + max_pooling2d_4 (MaxPoolin (None, 8, 8, 64) 0 + g2D) + + dropout_1 (Dropout) (None, 8, 8, 64) 0 + + conv2d_10 (Conv2D) (None, 8, 8, 64) 36928 + + conv2d_11 (Conv2D) (None, 8, 8, 64) 36928 + + max_pooling2d_5 (MaxPoolin (None, 4, 4, 64) 0 + g2D) + + dropout_2 (Dropout) (None, 4, 4, 64) 0 + + flatten_1 (Flatten) (None, 1024) 0 + + dense_2 (Dense) (None, 512) 524800 + + dropout_3 (Dropout) (None, 512) 0 + + dense_3 (Dense) (None, 10) 5130 + + ================================================================= + Total params: 669354 (2.55 MB) + Trainable params: 669354 (2.55 MB) + Non-trainable params: 0 (0.00 Byte) + _________________________________________________________________ + + + +```python +model_dropout.compile(optimizer='rmsprop', + loss='categorical_crossentropy', + metrics=['accuracy'], + ) +``` + + +```python +history = model_dropout.fit(X_train, + y_train, + batch_size=TrainingConfig.BATCH_SIZE, + epochs=TrainingConfig.EPOCHS, + verbose=1, + validation_split=.3, + ) +``` + + Epoch 1/31 + 137/137 [==============================] - 8s 34ms/step - loss: 2.1466 - accuracy: 0.2049 - val_loss: 2.0399 - val_accuracy: 0.2543 + Epoch 2/31 + 137/137 [==============================] - 5s 36ms/step - loss: 1.8586 - accuracy: 0.3310 - val_loss: 1.6229 - val_accuracy: 0.4019 + Epoch 3/31 + 137/137 [==============================] - 4s 27ms/step - loss: 1.6434 - accuracy: 0.4079 - val_loss: 1.4500 - val_accuracy: 0.4736 + Epoch 4/31 + 137/137 [==============================] - 4s 28ms/step - loss: 1.4957 - accuracy: 0.4597 - val_loss: 1.3105 - val_accuracy: 0.5251 + Epoch 5/31 + 137/137 [==============================] - 4s 26ms/step - loss: 1.3728 - accuracy: 0.5065 - val_loss: 1.3360 - val_accuracy: 0.5172 + Epoch 6/31 + 137/137 [==============================] - 4s 30ms/step - loss: 1.2613 - accuracy: 0.5488 - val_loss: 1.3085 - val_accuracy: 0.5423 + Epoch 7/31 + 137/137 [==============================] - 4s 26ms/step - loss: 1.1760 - accuracy: 0.5827 - val_loss: 1.0483 - val_accuracy: 0.6257 + Epoch 8/31 + 137/137 [==============================] - 4s 29ms/step - loss: 1.1000 - accuracy: 0.6099 - val_loss: 0.9638 - val_accuracy: 0.6559 + Epoch 9/31 + 137/137 [==============================] - 4s 28ms/step - loss: 1.0316 - accuracy: 0.6346 - val_loss: 0.9656 - val_accuracy: 0.6584 + Epoch 10/31 + 137/137 [==============================] - 4s 29ms/step - loss: 0.9723 - accuracy: 0.6551 - val_loss: 0.9065 - val_accuracy: 0.6806 + Epoch 11/31 + 137/137 [==============================] - 4s 29ms/step - loss: 0.9263 - accuracy: 0.6726 - val_loss: 0.8328 - val_accuracy: 0.7091 + Epoch 12/31 + 137/137 [==============================] - 4s 29ms/step - loss: 0.8802 - accuracy: 0.6909 - val_loss: 0.8497 - val_accuracy: 0.7026 + Epoch 13/31 + 137/137 [==============================] - 4s 28ms/step - loss: 0.8335 - accuracy: 0.7038 - val_loss: 0.8664 - val_accuracy: 0.6953 + Epoch 14/31 + 137/137 [==============================] - 4s 26ms/step - loss: 0.8004 - accuracy: 0.7174 - val_loss: 0.8244 - val_accuracy: 0.7139 + Epoch 15/31 + 137/137 [==============================] - 4s 29ms/step - loss: 0.7768 - accuracy: 0.7269 - val_loss: 0.7989 - val_accuracy: 0.7231 + Epoch 16/31 + 137/137 [==============================] - 4s 29ms/step - loss: 0.7370 - accuracy: 0.7401 - val_loss: 0.7107 - val_accuracy: 0.7546 + Epoch 17/31 + 137/137 [==============================] - 4s 26ms/step - loss: 0.7163 - accuracy: 0.7487 - val_loss: 0.7445 - val_accuracy: 0.7460 + Epoch 18/31 + 137/137 [==============================] - 4s 29ms/step - loss: 0.6881 - accuracy: 0.7579 - val_loss: 0.6884 - val_accuracy: 0.7600 + Epoch 19/31 + 137/137 [==============================] - 4s 27ms/step - loss: 0.6670 - accuracy: 0.7633 - val_loss: 0.6727 - val_accuracy: 0.7661 + Epoch 20/31 + 137/137 [==============================] - 4s 26ms/step - loss: 0.6448 - accuracy: 0.7722 - val_loss: 0.7363 - val_accuracy: 0.7433 + Epoch 21/31 + 137/137 [==============================] - 4s 28ms/step - loss: 0.6266 - accuracy: 0.7790 - val_loss: 0.6804 - val_accuracy: 0.7686 + Epoch 22/31 + 137/137 [==============================] - 4s 29ms/step - loss: 0.6086 - accuracy: 0.7865 - val_loss: 0.6885 - val_accuracy: 0.7609 + Epoch 23/31 + 137/137 [==============================] - 4s 26ms/step - loss: 0.5923 - accuracy: 0.7921 - val_loss: 0.7677 - val_accuracy: 0.7401 + Epoch 24/31 + 137/137 [==============================] - 4s 28ms/step - loss: 0.5711 - accuracy: 0.7998 - val_loss: 0.7026 - val_accuracy: 0.7614 + Epoch 25/31 + 137/137 [==============================] - 4s 28ms/step - loss: 0.5580 - accuracy: 0.8035 - val_loss: 0.6414 - val_accuracy: 0.7824 + Epoch 26/31 + 137/137 [==============================] - 4s 29ms/step - loss: 0.5387 - accuracy: 0.8097 - val_loss: 0.7137 - val_accuracy: 0.7622 + Epoch 27/31 + 137/137 [==============================] - 4s 26ms/step - loss: 0.5267 - accuracy: 0.8132 - val_loss: 0.6783 - val_accuracy: 0.7748 + Epoch 28/31 + 137/137 [==============================] - 4s 29ms/step - loss: 0.5143 - accuracy: 0.8167 - val_loss: 0.6377 - val_accuracy: 0.7879 + Epoch 29/31 + 137/137 [==============================] - 4s 29ms/step - loss: 0.5033 - accuracy: 0.8238 - val_loss: 0.6172 - val_accuracy: 0.7927 + Epoch 30/31 + 137/137 [==============================] - 4s 28ms/step - loss: 0.4858 - accuracy: 0.8275 - val_loss: 0.6394 - val_accuracy: 0.7884 + Epoch 31/31 + 137/137 [==============================] - 4s 27ms/step - loss: 0.4810 - accuracy: 0.8299 - val_loss: 0.6545 - val_accuracy: 0.7846 + + +## 드롭아웃이 적용된 훈련 결과 플로팅 + + +```python +# Retrieve training results. +train_loss = history.history["loss"] +train_acc = history.history["accuracy"] +valid_loss = history.history["val_loss"] +valid_acc = history.history["val_accuracy"] + +plot_results([ train_loss, valid_loss ], + ylabel="Loss", + ylim = [0.0, 5.0], + metric_name=["Training Loss", "Validation Loss"], + color=["g", "b"]); + +plot_results([ train_acc, valid_acc ], + ylabel="Accuracy", + ylim = [0.0, 1.0], + metric_name=["Training Accuracy", "Validation Accuracy"], + color=["g", "b"]) +``` + + + +![png](/images/2024/05/2024-05-31-02-output_24_0.png) + + + + + +![png](/images/2024/05/2024-05-31-02-output_24_1.png) + + + + +```python +# 모델 저장 +model_dropout.save('model_dropout') +``` + + +```python +from tensorflow.keras import models +reloaded_model_dropout = models.load_model('model_dropout') +``` + + +```python +# 테스트 데이터 세트에서 모델 평가 +test_loss, test_acc = reloaded_model_dropout.evaluate(X_test, y_test) +print(f"Test accuracy: {test_acc*100:.3f}") +``` + + 313/313 [==============================] - 2s 5ms/step - loss: 0.6712 - accuracy: 0.7822 + Test accuracy: 78.220 + + +## 샘플 테스트 이미지 예측 + + +```python +def evaluate_model(dataset, model): + + class_names = ['airplane', + 'automobile', + 'bird', + 'cat', + 'deer', + 'dog', + 'frog', + 'horse', + 'ship', + 'truck' ] + num_rows = 3 + num_cols = 6 + + # Retrieve a number of _images/2024/05 from the dataset. + data_batch = dataset[0:num_rows*num_cols] + + # Get predictions from model. + predictions = model.predict(data_batch) + + plt.figure(figsize=(20, 8)) + num_matches = 0 + + for idx in range(num_rows*num_cols): + ax = plt.subplot(num_rows, num_cols, idx + 1) + plt.axis("off") + plt.imshow(data_batch[idx]) + + pred_idx = tf.argmax(predictions[idx]).numpy() + truth_idx = np.nonzero(y_test[idx]) + + title = str(class_names[truth_idx[0][0]]) + " : " + str(class_names[pred_idx]) + title_obj = plt.title(title, fontdict={'fontsize':13}) + + if pred_idx == truth_idx: + num_matches += 1 + plt.setp(title_obj, color='g') + else: + plt.setp(title_obj, color='r') + + acc = num_matches/(idx+1) + print("Prediction accuracy: ", int(100*acc)/100) + + return +``` + + +```python +evaluate_model(X_test, reloaded_model_dropout) +``` + + 1/1 [==============================] - 0s 289ms/step + Prediction accuracy: 0.83 + + + + +![png](/images/2024/05/2024-05-31-02-output_30_1.png) + + + + +### References +https://learnopencv.com/implementing-cnn-tensorflow-keras/ \ No newline at end of file diff --git a/_posts/2024/06/2024-06-05-A_Comprehensive_Survey_on_Transfer_Learning.md b/_posts/2024/06/2024-06-05-A_Comprehensive_Survey_on_Transfer_Learning.md new file mode 100644 index 000000000000..ae647ba12810 --- /dev/null +++ b/_posts/2024/06/2024-06-05-A_Comprehensive_Survey_on_Transfer_Learning.md @@ -0,0 +1,62 @@ +--- +layout: single +title: "Review - A Comprehensive Survey on Transfer Learning" +categories: AI +tag: Paper Review +--- + +Transfer Learning(전이 학습)에 대한 서베이 논문 리뷰 발표자료 + +- 전이 학습의 정의 +- 다양한 전이 학습 소개(동종 전이 위주) +- 데이터 및 모델 관점에서의 전이 학습 + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.001.png) + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.002.png) + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.003.png) + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.004.png) + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.005.png) + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.006.png) + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.007.png) + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.008.png) + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.009.png) + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.010.png) + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.011.png) + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.012.png) + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.013.png) + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.014.png) + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.015.png) + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.016.png) + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.017.png) + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.018.png) + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.019.png) + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.020.png) + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.021.png) + +![png](/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.022.png) + +### Reference +A Comprehensive Survey on Transfer Learning - +Fuzhen Zhuang, Zhiyuan Qi, Keyu Duan, Dongbo Xi, Yongchun Zhu, Hengshu Zhu, Senior Member, IEEE, Hui Xiong, Fellow, IEEE, and Qing He / +Published In: Proceedings of the IEEE, Date of Publication: 07 July 2020 + diff --git a/_posts/2024/06/2024-06-17-CloudComputing overview.md b/_posts/2024/06/2024-06-17-CloudComputing overview.md new file mode 100644 index 000000000000..f14f40785bf8 --- /dev/null +++ b/_posts/2024/06/2024-06-17-CloudComputing overview.md @@ -0,0 +1,83 @@ +--- +layout: single +title: Cloud Computing Overview +categories: + - Cloud Computing +tags: + - Cloud-Computing +toc: true +--- +### 클라우드의 역사 +- 1960년대 가상화 용어 사용 + - 전 가상화 기법 구현 + - 에뮬레이터 존재 + +- 다양한 하이퍼바이저 출현 + - IBM Logical Partition + - IBM 유닉스 머신에 사용되는 하이퍼바이저 + - VMWare + - Xen + - KVM + - Hyper-V + +### 서버 가상화 +1. 전통 OS 작동 방식 vs Hypervisor +2. Type 1 vs Type 2 +3. Type 1 -> 전가상화 / 반가상화 + +### Type 1 vs Type 2 +Type 1 : Native (bare metal) +- IBM Xen +- VMWare ESX Server +- MS Hyper-V +- KVM + +Type 2 : Hosted +- VMware Server +- Vmware Workstation +- MS Virtual Server +- Oracle Virtual Box + +### 전가상화 vs 반가상화 +전가상화(Full Virtualization) +- 하드웨어 모두 가상화 +- 게스트 OS가 직접 CPU에게 하드웨어 제어 요청 + +반가상화(Para-Virtualization) +- 하드웨어 완전 가상화 X +- 게스트 OS가 하이퍼바이저에 하드웨어 제어 요청 + + +### Why Cloud? +스케일업, 스케일 아웃 이미지 +- 효율적인 비용 절감 + - 사용한 만큼 지불 등 기회 비용 최적화 -> 비용 절감 + - 다양한 부가 상품 이용을 통해 개발 비용 절감 +- 빠른 Deploy + - 기존 Legacy 인프라에 비해 빠른 인프라 구성 시간 +- 글로벌 진출 시 용이 + - 글로벌 리전 활용을 통해 글로벌 진출 시 빠르고 손쉬운 인프라 구성 +- 보안 + - 인프라에 대한 보안을 CSP(클라우드 공급 업체)에 위임 + - 다양한 보안 상품을 이용하여 보안 강화 + +### Cloud 모델 분류 +On-premise, IaaS, PaaS, SaaS 분류 이미지 + +IaaS 예시 +PaaS 예시 +SaaS 예시 + +### Deployment Model + +| 구분 | Private Cloud | Public Cloud | +| ------ | -------------------- | --------------------------------------------------------------------- | +| 서비스 대상 | 한정된 그룹 | 불특정 다수 | +| 인프라 위치 | 자체 데이터센터 | CSP 데이터센터 | +| 인프라 운영 | 사내 엔지니어 | CSP 엔지니어 | +| 장점 | 기업이 원하는 설계대로 구축 및 운영 | 초기 구축 비용 저렴
인프라 환경 운영 부담 X
트래픽 빠른 대응 가능
PaaS, SaaS 이용한 빠른 개발 | + +Multi Cloud + +Hybrid Cloud + diff --git a/_posts/2024/06/2024-06-17-Naver Cloud Associate 1.md b/_posts/2024/06/2024-06-17-Naver Cloud Associate 1.md new file mode 100644 index 000000000000..f31b5b329eb4 --- /dev/null +++ b/_posts/2024/06/2024-06-17-Naver Cloud Associate 1.md @@ -0,0 +1,10 @@ +--- +layout: single +title: Naver Cloud Associate +categories: + - Cloud Computing +tags: + - Cloud-Computing + - Certification +--- +![](/images/2024/06/NaverCloudPlatform.png) \ No newline at end of file diff --git a/_posts/2024/06/2024-06-28-whatisweb3.0.md b/_posts/2024/06/2024-06-28-whatisweb3.0.md new file mode 100644 index 000000000000..6ae5e35107f6 --- /dev/null +++ b/_posts/2024/06/2024-06-28-whatisweb3.0.md @@ -0,0 +1,54 @@ +--- +layout: single +title: 웹 3.0이란 무엇일까?(웹 1.0, 2.0과 차이) +categories: Tech-Insight +tags: [WEB 3.0, Insight, Trend] +toc: true +--- + +주로 블록체인과 연관된 키워드로 많이 보이는 웹 3.0의 정의는 대체 뭘까 궁금해서 찾아봤다. + +## 웹 3.0: 미래의 웹 + +웹 3.0은 현재 웹 기술의 다음 단계로, "세맨틱 웹"이라고도 함
+-> 이는 기존 웹의 정보를 단순히 보여주는 것을 넘어,
+웹이 정보를 이해하고 해석할 수 있게 만들어 주는 기술
+웹 3.0은 사용자에게 더욱 개인화된 경험을 제공하고, 정보 검색과 공유를 더 효율적으로 만들어 줄 것임. + +### 웹 1.0, 웹 2.0, 그리고 웹 3.0 비교 + +|특성|웹 1.0|웹 2.0|웹 3.0| +|---|---|---|---| +|**내용**|단순한 정보 제공|사용자 참여와 상호작용|의미론적 이해와 지능적 기능| +|**기술**|정적인 HTML 페이지|동적인 웹 애플리케이션 (AJAX 등)|세맨틱 웹 기술 (RDF, OWL, SPARQL)| +|**사용자 경험**|정보 소비자|정보 생산자 및 공유자|개인화된 경험과 효율적인 검색| +|**예시**|초기 웹사이트 (예: 야후 디렉토리)|소셜 미디어, 블로그, 위키피디아|개인화된 추천 시스템, 음성 인식| + +#### 웹 1.0: 정보 제공의 시대 + +- 웹 1.0은 1990년대 초반부터 2000년대 초반까지의 웹을 의미 +- 이 시기의 웹은 주로 정적인 HTML 페이지로 구성되어 있으며, 사용자는 정보를 읽기만 가능 +- ex) 야후 디렉토리와 같은 초기 웹사이트들이 웹 1.0의 대표적인 예시 + +#### 웹 2.0: 상호작용의 시대 + +- 웹 2.0은 2000년대 중반부터 시작되어 현재까지 이어지는 웹의 형태 +- 이 시기의 웹은 사용자가 정보를 생성하고 공유할 수 있음 +- 소셜 미디어, 블로그, 위키피디아 등은 웹 2.0의 대표적인 예시 +- AJAX와 같은 기술을 통해 웹 페이지가 동적으로 변하고, 사용자와의 상호작용이 강화 + +#### 웹 3.0: 지능형 웹의 시대 + +웹 3.0은 현재 발전 중인 웹의 새로운 단계로, +- 세맨틱 웹 기술을 통해 정보를 의미론적으로 이해하고 처리할 수 있음 +- 이를 통해 컴퓨터는 정보를 더 잘 이해하고, 사용자에게 더 정확하고 유용한 정보를 제공 가능 +- ex) 사용자의 관심사와 선호도를 분석하여 맞춤형 컨텐츠를 추천하거나, 음성 인식을 통해 웹을 제어할 수 있는 기능 +- 웹 3.0은 인공지능과의 결합을 통해 더욱 지능적인 웹 서비스를 제공하며, 사용자에게 보다 개인화된 경험을 제공 + +#### 참고 + +|기술|설명| +|---|---| +|RDF(Resource Description Framework)|- RDF는 웹 3.0에서 사용되는 표준 방법으로, 정보를 표현하기 위한 기술
- RDF는 웹 상의 자원에 대한 설명을 기술하며, 세맨틱 웹에서 정보를 의미론적으로 표현하고 연결하는 데 사용
- RDF 1.0은 2004년에, RDF 1.1은 2014년에 발표됐음.| +|OWL(Web Ontology Language)|- OWL은 RDF 위에 구축된 웹 온톨로지 언어
- OWL은 정보를 의미론적으로 표현하고 추론하는 데 사용
- OWL은 RDF 데이터를 기반으로 개념, 속성, 관계 등을 정의하여 웹 상의 지식을 표현함.
- OWL은 RDF와 함께 사용| +|SPARQL(SPARQL Protocol and RDF Query Language)|SPARQL은 RDF 그래프를 쿼리하고 조작하기 위한 표준 쿼리 언어입니다. SPARQL은 SQL과 유사한 문법을 가지며, RDF 데이터에서 원하는 정보를 추출하고 복잡한 질의를 수행할 수 있습니다. SPARQL은 2008년에 W3C의 권고안으로 발표되었습니다.| \ No newline at end of file diff --git a/_posts/2024/07/2024-07-26-dataStorage.md b/_posts/2024/07/2024-07-26-dataStorage.md new file mode 100644 index 000000000000..ff1702a03e60 --- /dev/null +++ b/_posts/2024/07/2024-07-26-dataStorage.md @@ -0,0 +1,30 @@ +--- +layout: single +title: 데이터 스토리지 종류 +categories: +tags: [] +toc: true +--- + +### 스토리지 종류 +- DAS +- NAS +- SAN + +#### 스토리지 역할 +1. DAS +- 호스트에 저장 장치가 직접 연결 +- ex) USB, 외장하드 등 +- 장점 + - 호스트와 저장 장치가 물리적으로 가까움 + - 확장 난이도가 낮음 +- 단점 + - 데이터 증가로 인해 외부 저장 장치를 지속적으로 추가하면 운영 효율성이 떠어짐 + - 호스트에 장애 발생 시 저장 장치 접근 제한 + - 물리적인 공간에 여유가 없으면 확장이 어려움 + +2. NAS + +3. SAN + + diff --git a/_posts/2024/07/2024-07-30-LocalYumRepository.md b/_posts/2024/07/2024-07-30-LocalYumRepository.md new file mode 100644 index 000000000000..816631f3d241 --- /dev/null +++ b/_posts/2024/07/2024-07-30-LocalYumRepository.md @@ -0,0 +1,128 @@ +--- +layout: single +title: CentOS 7, Local Yum Repository 만들기 +categories: Linux +tags: [CentOS 7,Yum,Repository] +toc: true +--- + +외부와 통신이 되지 않는 상태의 로컬 서버에서 yum을 사용하기 위한 설정입니다. + +## 기본 설정 + +하이퍼바이저 : Hyper-V + +Linux : CentOS-7-x86_64-DVD-2009.iso + +--- + +### 1. Hyper-V VM 생성 + +메모리 : 임의 설정 +네트워크 : 연결되지 않음 + +![](/images/2024/07/2024-07-30-LocalYumRepository/1-HyperV.png) + +### 2. CentOS 7 Install setting + +SOFTWARE SELECTION : Minimal Install + +NETWORK & HOST NAME : Not connected + +ROOT PASSWORD : 임의 설정 + +USER CREATION : No User + +![](/images/2024/07/2024-07-30-LocalYumRepository/2-ServerSetting.png) + +![](/images/2024/07/2024-07-30-LocalYumRepository/3-ServerSetting.png) + + +### 3. Server Setting + +1. Hyper-V에서 디스크 삽입 + - DVD나 Everyting iso를 사용해야 패키지를 전부 사용할 수 있음 + - Repository 생성을 하기 위해 필요한 createrepo 패키지는 Minimal iso 파일에 없음 + +2. 디스크 마운트 + - 삽입한 디스크(Hyper-V 기준 /dev/cdrom)를 원하는 위치(저는 /mnt)에 마운트 + - mount /dev/cdrom /mnt + +3. 마운트된 디렉토리 내용을 원하는 위치에 복사 + +```bash +mkdir -p /root/local-repo/CentOS_7 + +cp -r /mnt/Packages /root/local-repo/CentOS_7 + +cp -r /mnt/repodata /root/local-repo/CentOS_7 + +ls /root/local-repo/CentOS_7 + +Pcakages와 Repodata가 모두 있어야 함 + +umount /mnt +``` + +4. createrepo 설치 + +```bash +# createrepo 설치 확인 + +yum list installed | grep createrepo + +# 복사한 패키지 위치로 이동하여 createrepo 설치 + +cd /root/local-repo/CentOS_7/Packages + +ls | grep createrepo + +rpm -ivh createrepo...rpm + +# Failed dependencies가 발생하여 필요한 의존성 패키지 설치함(3개 패키지 추가설치) + +rpm -ivh deltarpm~.rpm + +rpm -ivh libxml2-python~.rpm + +rpm -ivh python-delarpm~.rpm + +rpm -ivh createrepo~.rpm +``` + +![](/images/2024/07/2024-07-30-LocalYumRepository/4-TestServer1 mount.png) + +![](/images/2024/07/2024-07-30-LocalYumRepository/5-cp Packages.png) + +![](/images/2024/07/2024-07-30-LocalYumRepository/6-rpm install dependencies.png) + +### 4. createrepo 설정 + +```bash +# 패키지 복사한 위치에 createrepo 지정 +createrepo /root/local-repo/CentOS_7 +``` + +![](/images/2024/07/2024-07-30-LocalYumRepository/7-createrepo.png) + +### 5. yum repository 설정 + +```bash +# 기존 설정된 yum 설정 초기화 +yum clean all + +yum repolist +``` + +![](/images/2024/07/2024-07-30-LocalYumRepository/8-yum repolist.png) + +### 6. Local yum repository 사용해보기 + +```bash +# 저는 vim을 설치해봤습니다. +yum install vim -y +``` + +![](/images/2024/07/2024-07-30-LocalYumRepository/9-yum install.png) + +--- diff --git a/_posts/2024/07/2024-07-31-YumRepositoryServer.md b/_posts/2024/07/2024-07-31-YumRepositoryServer.md new file mode 100644 index 000000000000..16f4d55e9b09 --- /dev/null +++ b/_posts/2024/07/2024-07-31-YumRepositoryServer.md @@ -0,0 +1,156 @@ +--- +layout: single +title: CentOS 7, Yum Repository 서버 만들기 +categories: Linux +tags: [CentOS 7,Yum, Repository] +toc: true +--- +이전에 Local Yum Repository를 만들어봤는데 +이번엔 이전에 만든 서버를 Yum Repository Server로 활용해보려고 한다. + +### Hyper-V 스위치 생성 +Hyper-V Internal Switch + +![](/images/2024/07/2024-07-31-YumRepositoryServer/1-Hyper-V-internalSwitch.png) + +### 네트워크 어댑터 수정 + +Windows 네트워크 설정에서 yumrepo TCP/IPv4의 속성을 원하는 대역대로 설정했음 +IP: 192.168.123.1 +NM: 255.255.255.0 +![](/images/2024/07/2024-07-31-YumRepositoryServer/1-1-network-adpater-config.png) + + +내부망에서 통신할 수 있는 환경으로 진행하기 위해 VM들의 네트워크 어댑터는 모두 yumrepo로 지정되어 있어야 합니다. + +![](/images/2024/07/2024-07-31-YumRepositoryServer/6-Hyper-V-NetworkAdpater.png) + +아래는 서버에서 고정 IP로 할당할 주소입니다. + +TestServer1 +IP: 192.168.123.99 +NM: 255.255.255.0 +GW: 192.168.123.1 + +TestServer2 +IP: 192.168.123.2 +NM: 255.255.255.0 +GW: 192.168.123.1 + +TestServer3(Option) +IP: 192.168.123.3 +NM: 255.255.255.0 +GW: 192.168.123.1 + + +### CentOS 7 고정 IP 설정 + +- TestServer1(192.168.123.99) 외에 다른 VM도 동일한 방법으로 진행 + +#### TestServer1 + +```bash +yum install net-tools + +ifconfig + +# vim /etc/sysconfig/network-scripts/ifcfg-eth0 +ONBOOT=yes +IPADDR=192.168.123.99 +GATEWAY=192.168.123.1 +NETMASK=255.255.255.0 +# 저장 후 종료 + +service network restart + +``` + +#### TestServer2 + +```bash +vim /etc/sysconfig/network-scripts/ifcfg-eth0 +ONBOOT=yes +IPADDR=192.168.123.99 +GATEWAY=192.168.123.1 +NETMASK=255.255.255.0 + +ifup eth0 +``` + +![](/images/2024/07/2024-07-31-YumRepositoryServer/2-sysconfig-network-edit.png) + +![](/images/2024/07/2024-07-31-YumRepositoryServer/3-ifcfg-edit.png) + +![](/images/2024/07/2024-07-31-YumRepositoryServer/4-ifcfg-edit.png) + +![](/images/2024/07/2024-07-31-YumRepositoryServer/5-serviceRestart.png) + +### HTTPD 설치 + +- Master 서버가 될 TestServer1(192.168.123.99)에서 진행 + +```bash +yum install httpd -y + +# 편의상 방화벽 및 SELinux 꺼두는 세팅으로 진행 + +systemctl stop firewalld + +setenforce 0 + +systemctl start httpd + +mkdir /var/www/html/centos7_repo + +# 이전에 사용했던 로컬 레포지토리를 html 아래에 링크 +ln -s /root/local-repo/CentOS_7/ /var/www/html/centos7_repo/ + +# 권한이 없으면 httpd 서버로 접속 시 접근 불가능 +chmod 551 /root +chmod -R 711 /root/local-repo/ + +chown -R apache:apache /root/local-repo +``` + +### ping 테스트 + +- TestServer2에서 TestServer1으로 핑 테스트 + +![](/images/2024/07/2024-07-31-YumRepositoryServer/7-TestServer2-ipsetup.png) + +### repository 등록 + +```bash +# yumrepo +baseurl=http://192.168.123.99/centos7_repo/CentOS_7 +``` + +![](/images/2024/07/2024-07-31-YumRepositoryServer/8-TestServer2-repo.png) + +![](/images/2024/07/2024-07-31-YumRepositoryServer/9-TestServer2-repo2.png) + +![](/images/2024/07/2024-07-31-YumRepositoryServer/10-TestServer2-repolist.png) + +----- + +로컬 pc에서 192.168.123.99로 접속 시 웹페이지에서도 접근 가능하다. +편의를 위해 firewalld와 SELinux를 사용하지 않았고 +/root의 권한을 수정하여 사용하고 있는데 +추후 보안을 조금 더 신경 써서 만들어봐야겠다 + +[고쳐야 할 것] +1. root 계정 사용하지 않도록 계정 추가 +2. firewalld 룰 추가하여 사용 +3. SELinux 사용 고려 + + + + + + + + + + + + diff --git a/_posts/2024/08/2024-08-03-chronyserver.md b/_posts/2024/08/2024-08-03-chronyserver.md new file mode 100644 index 000000000000..b02af4ab330a --- /dev/null +++ b/_posts/2024/08/2024-08-03-chronyserver.md @@ -0,0 +1,9 @@ +--- +layout: single +title: CentOS 7, chrony 서버 만들기 +categories: Linux +tags: [CentOS 7,chrony,ntp] +toc: true +--- + +chrony 서버 구축 내용 작성 diff --git a/_posts/2024/08/2024-08-08-LinuxContainer.md b/_posts/2024/08/2024-08-08-LinuxContainer.md new file mode 100644 index 000000000000..2345bdd259f3 --- /dev/null +++ b/_posts/2024/08/2024-08-08-LinuxContainer.md @@ -0,0 +1,9 @@ +--- +layout: single +title: Linux Container +categories: Container +tags: [Container, Linux, Docker] +toc: true +--- + +Linux Container \ No newline at end of file diff --git a/_posts/2024/08/2024-08-13-server-virtualization.md b/_posts/2024/08/2024-08-13-server-virtualization.md new file mode 100644 index 000000000000..e96a55537706 --- /dev/null +++ b/_posts/2024/08/2024-08-13-server-virtualization.md @@ -0,0 +1,40 @@ +--- +layout: single +title: 서버 가상화 +categories: Virtualization +tags: [Virtualization, Infra, Server] +toc: true +--- + +Image : History of Virtualization + +### 가상화란 + +- 가상화의 일반적인 정의 + - Hypervisor 사용한 가상 머신 + +- 가상화의 예시 + - 서버 통합 + - 서버 급증 문제 해결 등 + +- 가상화의 장점 + - 비가상화 vs 가상화 + +### 가상화의 종류 + +- 가상화 종류 + - 하이퍼바이저 가상화(Type 1) + - 호스트 가상화(Type 2) + - 컨테이너 가상화 + +- CPU 동작 레벨 + - Ring 0~3 + +- 전가상화 + - root / non-root + - Trap&Emulate + - Binary Translation + +- 반가상화 + - Hypercall(Xen) + - KVM diff --git a/_posts/2024/08/2024-08-20-ubuntu-xrdp-error.md b/_posts/2024/08/2024-08-20-ubuntu-xrdp-error.md new file mode 100644 index 000000000000..f177f1e7de61 --- /dev/null +++ b/_posts/2024/08/2024-08-20-ubuntu-xrdp-error.md @@ -0,0 +1,116 @@ +--- +layout: single +title: ubuntu xrdp black screen +categories: Linux +tags: [linux, ubuntu, Server] +toc: true +--- + +## 에러 내용 +1. 원격 접속 시 독이 사라지거나 일부 기능 안됨 + - 검은 화면만 뜸 + - https://github.com/neutrinolabs/xrdp/issues/1723 + +2. 원격 접속 시 반응 속도가 너무 느림 + + +## 에러 환경 +- Hypervisor: Windows10 hyper-v +- ubuntu 24.04 desktop + + +### 1. xrdp 수정 + +``` +sudo systemctl stop xrdp +``` + +``` +# /etc/xrdp/startwm.sh 수정 + +export DESKTOP_SESSION=ubuntu +export GNOME_SHELL_SESSION_MODE=ubuntu +export XDG_CURRENT_DESKTOP=ubuntu:GNOME +``` + +``` +# option ~/.xsessionrc 수정 시(테스트 해봐야함) + +export GNOME_SHELL_SESSION_MODE=ubuntu +export XDG_CURRENT_DESKTOP=ubuntu:GNOME +export XDG_CONFIG_DIRS=/etc/xdg/xdg-ubuntu:/etc/xdg +``` + +``` +sudo systemctl restart xrdp +``` + +#### Reference +https://github.com/neutrinolabs/xrdp/issues/1723 +https://blog.naver.com/uof4949/223455170846 + + +### 2. TCP 커널 값 수정 + +``` +# /etc/xrdp/xrdp.ini 수정 +# tcp_send... 주석 해제 후 아래 값으로 변경 +... +tcp_send_buffer_bytes=4194304 +... +``` + +``` +sudo systemctl restart xrdp +``` + +#### Reference +https://www.reddit.com/r/Ubuntu/comments/1ceun0e/xrdp_extremely_slow/ + + + + + + + + + + + + + + + + +Image : History of Virtualization + +### 가상화란 + +- 가상화의 일반적인 정의 + - Hypervisor 사용한 가상 머신 + +- 가상화의 예시 + - 서버 통합 + - 서버 급증 문제 해결 등 + +- 가상화의 장점 + - 비가상화 vs 가상화 + +### 가상화의 종류 + +- 가상화 종류 + - 하이퍼바이저 가상화(Type 1) + - 호스트 가상화(Type 2) + - 컨테이너 가상화 + +- CPU 동작 레벨 + - Ring 0~3 + +- 전가상화 + - root / non-root + - Trap&Emulate + - Binary Translation + +- 반가상화 + - Hypercall(Xen) + - KVM diff --git a/_posts/2024/09/2024-09-13-Writing a Business Plan_sequoia.md b/_posts/2024/09/2024-09-13-Writing a Business Plan_sequoia.md new file mode 100644 index 000000000000..4c9a6d3f955a --- /dev/null +++ b/_posts/2024/09/2024-09-13-Writing a Business Plan_sequoia.md @@ -0,0 +1,68 @@ +--- +layout: single +title: Writing a Business Plan by Sequoia +categories: Tech-Insight, Capstone-Project +tags: [Insight, Capstone-Project] +toc: false +--- + +벌써 대학원 마지막 학기가 됐습니다. +졸업시험이나 기타 자격증 공부를 회사다니며 병행하기엔 쉽지 않은 것 같아요. +그래도 어찌저찌 여기까지 왔네요... + +이번 학기에는 캡스톤 프로젝트를 듣게 됐고 +지금까지 배운 내용들을 망각의 저편에서 모두 끄집어내야 할 것 같습니다.. + +원래 쓰려고 한 내용은 수업 중 교수님께서 Sequoia Capital이라는 벤처 투자회사의 +사업 계획서 작성 방식을 소개해주시고 캡스톤 프로젝트를 준비하기 위해 활용하면 좋겠다고 하셔서 +고민하다가 내용이 되게 좋고 앞으로도 도움이 많이 될 것 같아서 블로깅해봅니다. + +이 원칙들?을 바탕으로 제 캡스톤 프로젝트의 주제와 방향성을 정하게 될 것 같네요. + +--- + +1. Company purpose +Define your company/business in a single declarative sentence. + +2. Problem +Describe the pain of your customer. +How is this addressed today and what are the shortcomings +to current solutions? + +3. Solution +Explain your eureka moment. +Why is your value prop unique and compelling? +Why will it endure? And where does it go from here? + +4. Why now ? +Why now? +Why hasn’t your solution been built before now? + +5. Market potential +Identify your customer and your market. +(Calculate the TAM, SAM, and SOM.) + +6. Competition / alternatives +Who are your direct and indirect competitors? +Show that you have a plan to win. + +7. Product +Product line-up +(For example, form factor, functionality, features, architecture, +intellectual property, etc.) + +8. Business model +How do you intend to thrive? +(For example - Revenue model, Pricing, Average account size +and/or lifetime value, Sales and distribution model, Customer/ +pipeline list, etc.) + +9. Team +Tell the story of your founders and key team members + +10. Financials +If you have any, please include. +P&L, Balance sheet, Cash flow, Cap table, The deal… + +11. Vision +If all goes well, what will you have built in five years? \ No newline at end of file diff --git a/_posts/2024/10/2024-10-25-Comparison of Virtualization Types.md b/_posts/2024/10/2024-10-25-Comparison of Virtualization Types.md new file mode 100644 index 000000000000..eb417bda1bbb --- /dev/null +++ b/_posts/2024/10/2024-10-25-Comparison of Virtualization Types.md @@ -0,0 +1,110 @@ +--- +layout: single +title: 가상화 종류 비교(Type 1, Type 2, Container) +categories: Infra +tags: [Virtualization, Hypervisor, Container] +toc: True +--- +### Type 비교 +Type 1 하이퍼바이저, Type 2 하이퍼바이저, 컨테이너의 차이를 설명하는 도표 + +| **항목** | **Type 1 하이퍼바이저** | **Type 2 하이퍼바이저** | **컨테이너** | +|------------------------------|-------------------------------------------------|-----------------------------------------------|----------------------------------------------------| +| **정의** | 하드웨어 위에서 직접 실행되는 하이퍼바이저. | 기존 운영체제 위에서 실행되는 하이퍼바이저. | 호스트 OS 커널을 공유하는 격리된 환경. | +| **호스트 운영체제** | 호스트 OS 없음, 하드웨어에서 직접 실행. | 호스트 OS가 필요함. | 호스트 OS 커널을 공유, 별도의 OS 필요 없음. | +| **성능** | 높은 성능 (거의 네이티브에 가까움). | 운영체제 오버헤드로 인해 성능이 다소 낮음. | 매우 높은 성능 (경량화). | +| **사용 용도** | 데이터 센터, 기업 수준의 가상화. | 데스크탑 가상화, 테스트 환경. | 클라우드 네이티브 애플리케이션, 마이크로서비스. | +| **부팅 시간** | 빠름, 시스템과 함께 부팅. | 느림, 호스트 OS에 의존. | 매우 빠름, 최소한의 부팅 시간. | +| **자원 활용도** | 효율적, 하드웨어 자원을 직접 관리. | 덜 효율적, 호스트 OS에 의존. | 매우 효율적, 최소한의 오버헤드. | +| **보안성** | 가상 머신 간의 높은 격리. | 중간 정도, 호스트 OS 보안에 의존. | 중간 정도, 커널 수준의 취약점은 모든 컨테이너에 영향.| +| **예시** | VMware ESXi, Microsoft Hyper-V, Xen. | VMware Workstation, Oracle VirtualBox. | Docker, Kubernetes (오케스트레이션). | +| **게스트 OS 요구사항** | 여러 OS 유형 실행 가능 (Linux, Windows 등). | 여러 OS 유형 실행 가능 (Linux, Windows 등). | 호스트 OS 커널을 공유, 주로 Linux 기반. | + +--- + +### Type 1 (Bare-metal) +- **Type 1 하이퍼바이저**는 하드웨어 위에서 직접 실행되어 성능과 효율성이 높으며, 주로 데이터 센터에 적합 + +``` +하드웨어 +└── Type 1 하이퍼바이저 (Bare-metal Hypervisor) + ├── 가상 머신 1 (Guest OS) + ├── 가상 머신 2 (Guest OS) + └── 가상 머신 N (Guest OS) +``` + +``` +┌─────────────────────────┐ +│ Guest Process │ +├─────────────────────────┤ +│ Guest OS │ +├─────────────────────────┤ +│ VM │ +├─────────────────────────┤ +│ Hypervisor │ +├─────────────────────────┤ +│ Hardware │ +└─────────────────────────┘ +``` + +--- + +### Type 2 (Hosted Hypervisor) +- **Type 2 하이퍼바이저**는 운영체제 위에서 실행되어 성능은 다소 낮지만 데스크탑이나 개발 환경에서 유용 + +``` +하드웨어 +└── 호스트 운영체제 (Host OS) + └── Type 2 하이퍼바이저 (Hosted) + ├── 가상 머신 1 (Guest OS) + ├── 가상 머신 2 (Guest OS) + └── 가상 머신 N (Guest OS) +``` + +``` +┌─────────────────────────┐ +│ Guest Process │ +├─────────────────────────┤ +│ Guest OS │ +├─────────────────────────┤ +│ VM │ +├─────────────────────────┤ +│ Hypervisor │ +├─────────────────────────┤ +│ Host OS │ +├─────────────────────────┤ +│ Hardware │ +└─────────────────────────┘ +``` + +--- + +### Container +- **컨테이너**는 호스트 OS 커널을 공유하면서 경량화된 격리 환경을 제공하며, 클라우드 네이티브 애플리케이션에 적합 + +``` +하드웨어 +└── 호스트 운영체제 (Host OS) + └── 컨테이너 런타임 (Docker 등) + ├── 컨테이너 1 (애플리케이션 1) + ├── 컨테이너 2 (애플리케이션 2) + └── 컨테이너 N (애플리케이션 N) +``` + +``` +┌─────────────────────────┐ +│ Guest Microservices │ +├─────────────────────────┤ +│ Libs/Bins │ +├─────────────────────────┤ +│ Container │ +├─────────────────────────┤ +│ Container Engine │ +├─────────────────────────┤ +│ Host OS │ +├─────────────────────────┤ +│ Hardware │ +└─────────────────────────┘ +``` + +--- diff --git a/_posts/2024/11/2024-11-01-Comparison of Loadbalancer Types.md b/_posts/2024/11/2024-11-01-Comparison of Loadbalancer Types.md new file mode 100644 index 000000000000..3dc6c7426ef7 --- /dev/null +++ b/_posts/2024/11/2024-11-01-Comparison of Loadbalancer Types.md @@ -0,0 +1,108 @@ +--- +layout: single +title: 로드밸런서 종류 비교(L4, L7 종류와 특징) +categories: Infra +tags: [Loadbalancer] +toc: True +--- + +## Layer 4 Loadbalancer +L4 로드밸런서는 OSI 모델의 **4계층(전송 계층)**에서 동작하여 IP 주소와 포트를 기반으로 트래픽을 분산하는 방식 + +### L4 로드밸런싱 주요 특징 + +1. **IP 및 포트 기반 라우팅** + - L4 로드밸런서는 패킷의 **출발지 IP, 목적지 IP, 포트 번호**와 같은 전송 계층 정보를 사용하여 트래픽을 분산 + - 애플리케이션 레벨의 상세 정보에는 접근하지 않고, 전송 계층 정보만을 사용하여 빠르게 트래픽을 처리 + +2. **프로토콜 지원** + - TCP와 UDP와 같은 전송 계층 프로토콜을 주로 사용하며, HTTP, HTTPS 등의 애플리케이션 레벨 프로토콜에 대해 추가 기능은 제공하지 않음 + +3. **빠른 처리 속도** + - 데이터 페이로드(payload)를 검사하지 않으므로 L7 로드밸런서보다 **처리 속도가 빠르고 리소스 소모가 적음**. + - 네트워크 레벨에서의 패킷 처리를 하기 때문에 성능이 중요한 경우에 유리함 + +4. **클라이언트와 서버의 연결 유지** + - 클라이언트와 서버 간의 **세션을 유지**하며, 동일 클라이언트의 요청이 항상 같은 서버로 전달되도록 설정 가능 (예: IP 기반 세션 고정) + +5. **확장성** + - 트래픽을 여러 서버로 분산시켜 **서버 부하를 줄이고, 가용성을 높임**. + - 서버가 추가되거나 감소할 때 동적으로 분산 정책을 조정할 수 있음. + +6. **SSL 오프로딩 미지원** + - L4 로드밸런서는 주로 TCP/UDP 레벨에서 작동하므로 **SSL 오프로딩을 지원 안됨**. 암호화된 트래픽 처리는 L7 로드밸런서가 더 적합 + +7. **비용 효율성** + - 하드웨어나 소프트웨어 리소스를 덜 사용하기 때문에 L7 로드밸런서보다 상대적으로 **비용이 저렴**하며, 소규모 네트워크 환경에도 적합 + +8. **간단한 설정 및 관리** + - 복잡한 애플리케이션 정보가 필요 없으므로 **설정이 상대적으로 간단**하며, 고급 트래픽 분산 정책이 필요하지 않은 경우에 쉽게 적용할 수 있음 + +### 주 사용 사례 + +- **웹 서버의 기본 부하 분산** +- **동일한 서비스가 여러 서버에 제공될 때 단순 부하 분산을 원하는 경우** +- **SSL 암호화가 필요 없고 빠른 트래픽 처리가 요구되는 환경** + +L4 로드밸런서는 고속 트래픽 처리와 비용 효율성을 필요로 하는 경우 적합하며, L7보다 간단한 트래픽 관리가 필요할 때 사용 + +--- + +## Layer 7 Loadbalancer +L7 로드밸런서는 OSI 모델의 **7계층(애플리케이션 계층)**에서 동작하며, 애플리케이션 계층 정보를 기반으로 트래픽을 정교하게 분산 + +### L7 로드밸런싱 주요 특징 + +1. **애플리케이션 계층 정보 기반 라우팅** + - URL, 쿠키, HTTP 헤더, 클라이언트 IP와 같은 **애플리케이션 레벨의 정보**를 분석하여 트래픽을 분배 + - 트래픽의 내용에 따라 특정 서버로 요청을 분배할 수 있어 정교한 트래픽 관리 가능 + +2. **프로토콜 지원** + - HTTP/HTTPS와 같은 애플리케이션 레벨 프로토콜을 지원하며, 다양한 애플리케이션 정보를 기반으로 라우팅 가능 + - HTTP 메서드(GET, POST 등)나 쿠키, 세션 정보 등 다양한 요소를 기준으로 분산 정책을 설정할 수 있음. + +3. **SSL 오프로딩** + - SSL 인증서를 관리하고 암호화 트래픽을 해제하여 서버에 전달하므로, 서버의 부담을 줄여줌. + - HTTPS 트래픽을 해제하고 분석하여 트래픽을 분산할 수 있으므로 보안 및 성능을 동시에 강화할 수 있음. + +4. **정교한 로드밸런싱 정책** + - 애플리케이션 요구사항에 따라 다양한 조건을 설정하여 트래픽을 특정 서버에 분배 가능 + - 예를 들어 URL 경로에 따라 이미지 서버, API 서버 등으로 분리하여 트래픽을 분배 가능 + +5. **세션 지속성 (Sticky Session)** + - 클라이언트가 동일한 세션 동안 동일한 서버와 연결을 유지할 수 있게 하여 세션 정보를 지속적으로 관리할 수 있음. + - 세션 지속성은 주로 쿠키 기반이나 IP 기반 방식으로 설정 + +6. **트래픽 분석 및 최적화** + - 애플리케이션 레벨에서 트래픽을 분석하고, HTTP 압축, 캐싱 등 최적화 작업을 통해 트래픽 효율성을 높일 수 있음. + - 사용자가 요청하는 리소스의 콘텐츠에 따라 로드밸런싱을 조정할 수 있어 더 나은 사용자 경험을 제공 + +### 주 사용 사례 + +- **HTTP/HTTPS 기반 웹 애플리케이션의 부하 분산** +- **API 게이트웨이로서의 역할 수행** +- **정교한 트래픽 분배가 필요한 마이크로서비스 환경** +- **다양한 조건을 기반으로 한 복잡한 트래픽 분산 요구** + +--- + +## L4, L7 비교 테이블 + +| **로드밸런서 종류** | **L4 지원** | **L7 지원** | **주요 특징** | **지원 환경** | +|-------------------------------|-------------|-------------|------------------------------------------------|--------------------------------| +| **F5 BIG-IP** | O | O | 고성능, SSL 오프로딩, 고급 정책 설정 가능 | 물리적, 가상, 클라우드 | +| **Citrix ADC (NetScaler)** | O | O | TCP 최적화, SSL 오프로딩, 보안 기능 강화 | 물리적, 가상, 클라우드 | +| **A10 Networks - Thunder** | O | O | DDoS 방어, SSL 오프로딩, 고성능 | 물리적, 가상, 클라우드 | +| **AWS Network Load Balancer** | O | X | IP 및 포트 기반 트래픽 분산, Auto Scaling | AWS 클라우드 | +| **AWS Application Load Balancer** | X | O | HTTP/HTTPS 기반, 다양한 조건 라우팅 | AWS 클라우드 | +| **Google Cloud NLB** | O | X | TCP/UDP 트래픽 분산, 고정 IP 제공 | GCP 클라우드 | +| **Google Cloud HTTP(S) LB** | X | O | 글로벌 로드밸런싱, SSL 오프로딩 | GCP 클라우드 | +| **Microsoft Azure Load Balancer** | O | X | TCP/UDP 트래픽 기반 부하 분산 | Azure 클라우드 | +| **Microsoft Azure Application Gateway** | X | O | HTTP/HTTPS 기반, WAF 통합 | Azure 클라우드 | +| **Nginx** | O | O | 오픈소스, TCP/UDP 및 HTTP 라우팅 지원 | 가상 환경, 온프레미스 | +| **HAProxy** | O | O | 오픈소스, 고가용성, SSL 오프로딩 | 가상 환경, 온프레미스 | +| **Kemp LoadMaster** | O | O | 사용하기 쉬운 인터페이스, SSL 오프로딩 | 물리적, 가상, 클라우드 | +| **Traefik** | X | O | 컨테이너 네이티브, 자동 동적 설정 지원 | 컨테이너 환경 (Kubernetes 등) | +| **Envoy** | X | O | 서비스 메시, HTTP/2 및 gRPC 지원 | 컨테이너 환경 (Kubernetes 등) | +| **pfSense** | O | X | 오픈소스 방화벽, 저비용 솔루션 | 가상 환경, 온프레미스 | +| **Opnsense** | O | X | 오픈소스 방화벽, 소규모 네트워크 적합 | 가상 환경, 온프레미스 | diff --git a/_posts/2024/11/2024-11-28-Install Brew On Linux.md b/_posts/2024/11/2024-11-28-Install Brew On Linux.md new file mode 100644 index 000000000000..2538b3dec19f --- /dev/null +++ b/_posts/2024/11/2024-11-28-Install Brew On Linux.md @@ -0,0 +1,99 @@ +--- +layout: single +title: 우분투에 brew 설치하기 +categories: Linux +tags: ubuntu, brew +toc: True +--- + +설치환경 +Hyper-V +ubuntu-24.04.1-desktop +bash + +## Brew 설치하기 +### brew 설치하기 전에 필요한 build tools +https://docs.brew.sh/Homebrew-on-Linux#requirements +``` +# ex) 우분투 +sudo apt-get install build-essential procps curl file git +``` + +1. https://brew.sh/ +``` +/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" +``` + +2. .bashrc 수정 +``` +# 터미널에서 그대로 입력 +test -d ~/.linuxbrew && eval "$(~/.linuxbrew/bin/brew shellenv)" +test -d /home/linuxbrew/.linuxbrew && eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)" +echo "eval \"\$($(brew --prefix)/bin/brew shellenv)\"" >> ~/.bashrc +``` + +``` +# ~/.bashrc +... +eval "$(/bin/brew shellenv)" +eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)" +``` + +bash: /bin/brew: No such file or directory +이런 에러가 뜨는데 +eval "$(/bin/brew shellenv)" 라인을 삭제함 + +### 옵션 : 기본 쉘 zsh로 변경하기 +``` +# zsh 설치 +sudo apt install -y zsh + +# 현재 쉘 확인 +echo $SHELL + +# 쉘 변경 +sudo chsh -s /usr/bin/zsh + +# 터미널 재실행 +``` + +ubuntu gnome 터미널에선 기본 쉘이 bash로 고정돼있는 것 같습니다. +원격 접속으로 사용할 경우 zsh로 접속돼고 +만약 gnome 환경에서 zsh를 사용하고 싶다면 +gnome preferences 메뉴에서 Profile을 선택한 후 +Run a Custom command instead of my shell 체크, +Command -> Custom Command 에 /bin/zsh 를 입력하면 됩니다. + +![](/images/2024/11/2024-11-28-Install Brew On Linux_Image-01.png) + + +#### zsh에서도 brew를 사용할 수 있도록 export를 추가 +``` +# ~/.zshrc +# linuxbrew export +export PATH="/home/linuxbrew/.linuxbrew/bin:$PATH" +export MANPATH="/home/linuxbrew/.linuxbrew/share/man:$MANPATH" +export INFOPATH="/home/linuxbrew/.linuxbrew/share/info:$INFOPATH" +``` +#### ohmyzsh + +https://ohmyz.sh/#install + +폰트 설치(apt로 설치하거나, git clone 후 install.sh 실행) +https://github.com/powerline/fonts +설치 후 터미널 재실행하여 preferences에서 font 수정 + + +플러그인 설치 +``` +git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting +git clone https://github.com/zsh-users/zsh-autosuggestions${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions + +# ~/.zshrc의 plugins 부분 수정 +... +plugins=(git +zsh-syntax-highlighting +zsh-autosuggestions +) +... +``` \ No newline at end of file diff --git a/assets/images/404pageNotFound.png b/assets/images/404pageNotFound.png new file mode 100644 index 000000000000..d28791ddc47b Binary files /dev/null and b/assets/images/404pageNotFound.png differ diff --git a/assets/images/nyanCat_logo.png b/assets/images/nyanCat_logo.png new file mode 100644 index 000000000000..72fcd4a405da Binary files /dev/null and b/assets/images/nyanCat_logo.png differ diff --git a/google0f9fa7859fd3194f.html b/google0f9fa7859fd3194f.html new file mode 100644 index 000000000000..812021df1eef --- /dev/null +++ b/google0f9fa7859fd3194f.html @@ -0,0 +1 @@ +google-site-verification: google0f9fa7859fd3194f.html \ No newline at end of file diff --git a/images/2023/12/Devops.png b/images/2023/12/Devops.png new file mode 100644 index 000000000000..0c4c07f4c249 Binary files /dev/null and b/images/2023/12/Devops.png differ diff --git a/images/2023/test b/images/2023/test new file mode 100644 index 000000000000..e69de29bb2d1 diff --git a/images/2023/test2 b/images/2023/test2 new file mode 100644 index 000000000000..e69de29bb2d1 diff --git a/images/2023/test3 b/images/2023/test3 new file mode 100644 index 000000000000..e69de29bb2d1 diff --git a/images/2024/04/2024-04-16-Hyper-V_1.png b/images/2024/04/2024-04-16-Hyper-V_1.png new file mode 100644 index 000000000000..934a62d438e0 Binary files /dev/null and b/images/2024/04/2024-04-16-Hyper-V_1.png differ diff --git a/images/2024/04/2024-04-16-Hyper-V_10.png b/images/2024/04/2024-04-16-Hyper-V_10.png new file mode 100644 index 000000000000..2a4edde22ea1 Binary files /dev/null and b/images/2024/04/2024-04-16-Hyper-V_10.png differ diff --git a/images/2024/04/2024-04-16-Hyper-V_11.png b/images/2024/04/2024-04-16-Hyper-V_11.png new file mode 100644 index 000000000000..9763be359d69 Binary files /dev/null and b/images/2024/04/2024-04-16-Hyper-V_11.png differ diff --git a/images/2024/04/2024-04-16-Hyper-V_2.png b/images/2024/04/2024-04-16-Hyper-V_2.png new file mode 100644 index 000000000000..bbbbc4a016e6 Binary files /dev/null and b/images/2024/04/2024-04-16-Hyper-V_2.png differ diff --git a/images/2024/04/2024-04-16-Hyper-V_3.png b/images/2024/04/2024-04-16-Hyper-V_3.png new file mode 100644 index 000000000000..ceda9dd4cdf8 Binary files /dev/null and b/images/2024/04/2024-04-16-Hyper-V_3.png differ diff --git a/images/2024/04/2024-04-16-Hyper-V_4.png b/images/2024/04/2024-04-16-Hyper-V_4.png new file mode 100644 index 000000000000..f12617b3eea9 Binary files /dev/null and b/images/2024/04/2024-04-16-Hyper-V_4.png differ diff --git a/images/2024/04/2024-04-16-Hyper-V_5.png b/images/2024/04/2024-04-16-Hyper-V_5.png new file mode 100644 index 000000000000..45536b843a60 Binary files /dev/null and b/images/2024/04/2024-04-16-Hyper-V_5.png differ diff --git a/images/2024/04/2024-04-16-Hyper-V_6.png b/images/2024/04/2024-04-16-Hyper-V_6.png new file mode 100644 index 000000000000..97c6cfa025b4 Binary files /dev/null and b/images/2024/04/2024-04-16-Hyper-V_6.png differ diff --git a/images/2024/04/2024-04-16-Hyper-V_7.png b/images/2024/04/2024-04-16-Hyper-V_7.png new file mode 100644 index 000000000000..32709a4fb3d0 Binary files /dev/null and b/images/2024/04/2024-04-16-Hyper-V_7.png differ diff --git a/images/2024/04/2024-04-16-Hyper-V_8.png b/images/2024/04/2024-04-16-Hyper-V_8.png new file mode 100644 index 000000000000..bd8b03f3f621 Binary files /dev/null and b/images/2024/04/2024-04-16-Hyper-V_8.png differ diff --git a/images/2024/04/2024-04-16-Hyper-V_9.png b/images/2024/04/2024-04-16-Hyper-V_9.png new file mode 100644 index 000000000000..b0a6b08f8ac9 Binary files /dev/null and b/images/2024/04/2024-04-16-Hyper-V_9.png differ diff --git a/images/2024/05/2024-05-31-02-output_17_0.png b/images/2024/05/2024-05-31-02-output_17_0.png new file mode 100644 index 000000000000..861e9eccd5b8 Binary files /dev/null and b/images/2024/05/2024-05-31-02-output_17_0.png differ diff --git a/images/2024/05/2024-05-31-02-output_17_1.png b/images/2024/05/2024-05-31-02-output_17_1.png new file mode 100644 index 000000000000..efb0a36617b8 Binary files /dev/null and b/images/2024/05/2024-05-31-02-output_17_1.png differ diff --git a/images/2024/05/2024-05-31-02-output_24_0.png b/images/2024/05/2024-05-31-02-output_24_0.png new file mode 100644 index 000000000000..5c53905bf1cb Binary files /dev/null and b/images/2024/05/2024-05-31-02-output_24_0.png differ diff --git a/images/2024/05/2024-05-31-02-output_24_1.png b/images/2024/05/2024-05-31-02-output_24_1.png new file mode 100644 index 000000000000..4c66ecbbb590 Binary files /dev/null and b/images/2024/05/2024-05-31-02-output_24_1.png differ diff --git a/images/2024/05/2024-05-31-02-output_30_1.png b/images/2024/05/2024-05-31-02-output_30_1.png new file mode 100644 index 000000000000..ab01f8cf339a Binary files /dev/null and b/images/2024/05/2024-05-31-02-output_30_1.png differ diff --git a/images/2024/05/2024-05-31-02-output_5_0.png b/images/2024/05/2024-05-31-02-output_5_0.png new file mode 100644 index 000000000000..36601d2f495a Binary files /dev/null and b/images/2024/05/2024-05-31-02-output_5_0.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.001.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.001.png new file mode 100644 index 000000000000..2cfa7802b3ae Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.001.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.002.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.002.png new file mode 100644 index 000000000000..5dc559c33508 Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.002.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.003.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.003.png new file mode 100644 index 000000000000..7cf145871088 Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.003.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.004.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.004.png new file mode 100644 index 000000000000..f4aa31250dce Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.004.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.005.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.005.png new file mode 100644 index 000000000000..629f59cbd09c Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.005.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.006.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.006.png new file mode 100644 index 000000000000..5bc29643ae91 Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.006.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.007.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.007.png new file mode 100644 index 000000000000..989d85af7cdc Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.007.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.008.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.008.png new file mode 100644 index 000000000000..a64e9e695037 Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.008.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.009.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.009.png new file mode 100644 index 000000000000..07a2319c36e4 Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.009.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.010.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.010.png new file mode 100644 index 000000000000..74888587000e Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.010.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.011.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.011.png new file mode 100644 index 000000000000..1307c0ff6ecf Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.011.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.012.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.012.png new file mode 100644 index 000000000000..be7edfc4bd4e Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.012.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.013.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.013.png new file mode 100644 index 000000000000..1f5b6b30cde2 Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.013.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.014.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.014.png new file mode 100644 index 000000000000..fcba8b79deec Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.014.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.015.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.015.png new file mode 100644 index 000000000000..4e6bd843bf07 Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.015.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.016.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.016.png new file mode 100644 index 000000000000..2cf01dd1a848 Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.016.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.017.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.017.png new file mode 100644 index 000000000000..e08c1ca06714 Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.017.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.018.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.018.png new file mode 100644 index 000000000000..087489bb82e6 Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.018.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.019.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.019.png new file mode 100644 index 000000000000..67d33141aae1 Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.019.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.020.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.020.png new file mode 100644 index 000000000000..f27a5a53fc49 Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.020.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.021.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.021.png new file mode 100644 index 000000000000..559271ba3390 Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.021.png differ diff --git a/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.022.png b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.022.png new file mode 100644 index 000000000000..5d9a5ba85c0e Binary files /dev/null and b/images/2024/06/A Comprehensive Survey on Tranfer Learning_Image.022.png differ diff --git a/images/2024/06/A.md b/images/2024/06/A.md new file mode 100644 index 000000000000..e69de29bb2d1 diff --git a/images/2024/06/NaverCloudPlatform.png b/images/2024/06/NaverCloudPlatform.png new file mode 100644 index 000000000000..ed30c9d7f1c1 Binary files /dev/null and b/images/2024/06/NaverCloudPlatform.png differ diff --git a/images/2024/07/2024-07-30-LocalYumRepository/1-1-network-adpater-config.png b/images/2024/07/2024-07-30-LocalYumRepository/1-1-network-adpater-config.png new file mode 100644 index 000000000000..72f3d92d489c Binary files /dev/null and b/images/2024/07/2024-07-30-LocalYumRepository/1-1-network-adpater-config.png differ diff --git a/images/2024/07/2024-07-30-LocalYumRepository/1-HyperV.png b/images/2024/07/2024-07-30-LocalYumRepository/1-HyperV.png new file mode 100644 index 000000000000..0f75ecd5f589 Binary files /dev/null and b/images/2024/07/2024-07-30-LocalYumRepository/1-HyperV.png differ diff --git a/images/2024/07/2024-07-30-LocalYumRepository/2-ServerSetting.png b/images/2024/07/2024-07-30-LocalYumRepository/2-ServerSetting.png new file mode 100644 index 000000000000..2e373241d417 Binary files /dev/null and b/images/2024/07/2024-07-30-LocalYumRepository/2-ServerSetting.png differ diff --git a/images/2024/07/2024-07-30-LocalYumRepository/3-ServerSetting.png b/images/2024/07/2024-07-30-LocalYumRepository/3-ServerSetting.png new file mode 100644 index 000000000000..8b25584ed786 Binary files /dev/null and b/images/2024/07/2024-07-30-LocalYumRepository/3-ServerSetting.png differ diff --git a/images/2024/07/2024-07-30-LocalYumRepository/4-TestServer1 mount.png b/images/2024/07/2024-07-30-LocalYumRepository/4-TestServer1 mount.png new file mode 100644 index 000000000000..b5a79198a2bb Binary files /dev/null and b/images/2024/07/2024-07-30-LocalYumRepository/4-TestServer1 mount.png differ diff --git a/images/2024/07/2024-07-30-LocalYumRepository/5-cp Packages.png b/images/2024/07/2024-07-30-LocalYumRepository/5-cp Packages.png new file mode 100644 index 000000000000..a3c1468ece71 Binary files /dev/null and b/images/2024/07/2024-07-30-LocalYumRepository/5-cp Packages.png differ diff --git a/images/2024/07/2024-07-30-LocalYumRepository/6-rpm install dependencies.png b/images/2024/07/2024-07-30-LocalYumRepository/6-rpm install dependencies.png new file mode 100644 index 000000000000..7b8788ec1c51 Binary files /dev/null and b/images/2024/07/2024-07-30-LocalYumRepository/6-rpm install dependencies.png differ diff --git a/images/2024/07/2024-07-30-LocalYumRepository/7-createrepo.png b/images/2024/07/2024-07-30-LocalYumRepository/7-createrepo.png new file mode 100644 index 000000000000..d30e1b85abf2 Binary files /dev/null and b/images/2024/07/2024-07-30-LocalYumRepository/7-createrepo.png differ diff --git a/images/2024/07/2024-07-30-LocalYumRepository/8-yum repolist.png b/images/2024/07/2024-07-30-LocalYumRepository/8-yum repolist.png new file mode 100644 index 000000000000..76927353a486 Binary files /dev/null and b/images/2024/07/2024-07-30-LocalYumRepository/8-yum repolist.png differ diff --git a/images/2024/07/2024-07-30-LocalYumRepository/9-yum install.png b/images/2024/07/2024-07-30-LocalYumRepository/9-yum install.png new file mode 100644 index 000000000000..babc9713681d Binary files /dev/null and b/images/2024/07/2024-07-30-LocalYumRepository/9-yum install.png differ diff --git a/images/2024/07/test b/images/2024/07/test new file mode 100644 index 000000000000..c291c09129e3 --- /dev/null +++ b/images/2024/07/test @@ -0,0 +1 @@ +images diff --git a/images/2024/11/2024-11-28-Install Brew On Linux_Image-01.png b/images/2024/11/2024-11-28-Install Brew On Linux_Image-01.png new file mode 100644 index 000000000000..a8f53562d44a Binary files /dev/null and b/images/2024/11/2024-11-28-Install Brew On Linux_Image-01.png differ