itprofes
Bạn có muốn phản ứng với tin nhắn này? Vui lòng đăng ký diễn đàn trong một vài cú nhấp chuột hoặc đăng nhập để tiếp tục.

Upgrade Server 2008 - Windows PowerShell

Go down

Upgrade Server 2008 - Windows PowerShell Empty Upgrade Server 2008 - Windows PowerShell

Bài gửi  admin 25/6/2010, 8:41 am

Trong Windows Server 2008 Microsoft đã tích hợp thêm một công cụ mới là Winows PowerShell đây là một công cụ đời sau của DOS Command. Như vậy với PowerShell ta hoàn toàn có thể sử dụng các câu lệnh trong DOS Command tuy nhiên PowerShell còn có tính gợi nhớ lệnh khi bạn nhấn phím Tab và nhiều câu lệnh hơn DOS Command.

Windows PowerShell hỗ trợ các phiên bản Windows XP, Windows Server 2003 và Windows Vista.

Trong Windows Server 2008 để cài đặt Windows PowerShell bạn bật Server Manager lên chọn Featues -> Add Features

Upgrade Server 2008 - Windows PowerShell 20090115-223642-gf-thumb

Trong Select Feature bạn chọn Windows PowerShell (WPS) và tiến hành cài đặt WPS lên máy

Upgrade Server 2008 - Windows PowerShell 20090115-223716-gf-thumb

Sau khi cài đặt hoàn tất bạn vào Start -> Programs -> Windows PowerShell để chạy PWS

Upgrade Server 2008 - Windows PowerShell 20090114-224212-gf-thumb

Để xem tất cả các lệnh có trong PWS bạn nhập lệnh:

Help

Upgrade Server 2008 - Windows PowerShell 20090114-224431-gf-thumb

PWS thừa kế tất cả các lệnh của DOS Command nên trong PWS ta có thể sử dụng mọi lệnh trong DOS Command

Upgrade Server 2008 - Windows PowerShell 20090114-224531-gf-thumb

Để biết được cú pháp của một lệnh bạn nhập lệnh:

Get-Help [Tên lệnh]

Upgrade Server 2008 - Windows PowerShell 20090114-224639-gf-thumb

Để tạo một thư mục mới bạn sử dụng lệnh:

New-Item [Tên thư mục] - ItemType Directory

Upgrade Server 2008 - Windows PowerShell 20090114-224902-gf-thumb

Để tạo một tập tin mới bạn nhập lệnh:

Set-Content -path “[Đường dẫn tập tin]” -value “[Nội dung tập tin]“

Để xem nội dung một tập tin nào đó bạn nhập lệnh:

Get-Content “[Đường dẫn tập tin]“

Upgrade Server 2008 - Windows PowerShell 20090114-225318-gf-thumb

Để xóa một tập tin hoặc thư mục nào đó bạn nhập lệnh:

Remove-Item “[Đường dẫn tập tin hoặc đường dẫn thư mục]“

Upgrade Server 2008 - Windows PowerShell 20090114-225441-gf-thumb

Để xuất kết quả của một nội dung nào đó ra các tập tin khác ta sử dụng lệnh:

[Câu lệnh] > [Tập tin xuất ra/Đường dẫn tập tin xuất ra]

Để mở một tập tin nào đó với Notepad bạn nhập lệnh:

Notepad [Tên tập tin/Đường dẫn tập tin]

Upgrade Server 2008 - Windows PowerShell 20090114-225603-gf-thumb

Để xem thông tin hệ thống bạn nhập lệnh:

Get-Process

Upgrade Server 2008 - Windows PowerShell 20090114-225724-gf-thumb

Để đóng một chương trình nào đó của hệ thống bạn nhập câu lệnh:

Kill [ID của chương trình]

Upgrade Server 2008 - Windows PowerShell 20090114-225812-gf-thumb

Để xem thông tin về CPU bạn nhập lệnh:

Get-Wmiobject -Class win32_processor

Upgrade Server 2008 - Windows PowerShell 20090114-225953-gf-thumb
admin
admin
Thiếu Úy III
Thiếu Úy III

Tổng số bài gửi : 627
Diem : 6546
Thank : 4
Join date : 24/03/2010
Đến từ : Bỉm Sơn - Thanh hóa

https://itprofes.forumvi.com

Về Đầu Trang Go down

Về Đầu Trang

- Similar topics

 
Permissions in this forum:
Bạn không có quyền trả lời bài viết