Deliver mail addressed locally to support into user helpdesk's mailbox.
Write the entry in /etc/aliases.
Which line is appropriate?
/etc/aliases uses ALIAS: DESTINATION to expand a local recipient.
Detailed explanation
support: helpdeskCorrect. Mail to support is delivered to helpdesk.
Correct. Mail to support is delivered to helpdesk.
support -> helpdeskIncorrect. aliases does not use arrow syntax.
Incorrect. aliases does not use arrow syntax.
helpdesk: supportIncorrect. It reverses alias and destination.
Incorrect. It reverses alias and destination.
support = helpdeskIncorrect. aliases uses a colon, not equals.
Incorrect. aliases uses a colon, not equals.
Try it yourself
An example you can run in a temporary verification environment.
printf '%s
' 'support: helpdesk' | awk -F: '{print $1, $2}'Expected result
support helpdeskKey points
- Left side is alias
- Colon separates fields
- Right side is destination
Notes
- Environment: POSIX awk / 模擬設定のみ
- Command output formatting can vary slightly by distribution or tool version.
- Run the example in a temporary directory or process when possible.
Foundation review
Read the scope first
Check whether the command acts on the current shell, a new process, an existing process, or a file.
Verify the observable result
Use the supplied command and compare the output with the expected result.